Borrar filtros
Borrar filtros

How to plot a simple curve fitting in Matlab?

1 visualización (últimos 30 días)
Ayob
Ayob el 1 de En. de 2016
Respondida: KSSV el 1 de En. de 2016
Hi
I'm trying to use Matlab curve fittings. I used X=[1,2,3] and Y=[3,4,5] as known data and the codes introduced below:
f=fit(X,Y,'poly2')
plot(f,X,Y)
But it doesn't work! How should I edit it?

Respuesta aceptada

KSSV
KSSV el 1 de En. de 2016
Make X and Y a column vector. Or use f=fit(X',Y','poly2') ;

Más respuestas (0)

Categorías

Más información sobre Get Started with Curve Fitting Toolbox en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by