matlab - How to export fitted curve to 1D vector -


with use of curve fitting toolbox i'm fitting 11 data points curve described custom equation. result this:

enter image description here

i want save 1d vector represented bye red line on plot above matlab variable. try use fit->save workspace... option curve fitting toolbox menu, saved variables not contain of fitted data.

how can save fitted data matlab variable?

the saved matlab-object (default name fittedmodel) contains fitted function function-handle , fitted coefficients corresponding function-handle. can evaluate @ data points of choice feval.

in following example fitted function evaluated @ original datapoints x:

y = feval(fittedmodel, x); 

now can directly plot result:

plot(x,y); 

Comments

Popular posts from this blog

powershell Start-Process exit code -1073741502 when used with Credential from a windows service environment -

twig - Using Twigbridge in a Laravel 5.1 Package -

c# - LINQ join Entities from HashSet's, Join vs Dictionary vs HashSet performance -