How to upload a text file for a curve fit?

3 visualizaciones (últimos 30 días)
Dylan Wolf
Dylan Wolf el 21 de Abr. de 2018
Editada: Dylan Wolf el 21 de Abr. de 2018
I am trying to upload a text file so that i can use the data to create a reciprocal curve fit.
data1= importdata('10_Reciprocal.txt'); data=data1.data; x= data1(:,1); y=data1(:,1);
hold on p=polyfit(x,1./y,1); m=p(1); b=exp(p(2)); fplot(@(x) (1/m*x+b),[x(1) x(end)])

Respuestas (0)

Categorías

Más información sobre Interpolation 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