1 function [fitresult, gof] = createFit(x, y)
5 % Data for 'untitled fit 1' fit:
9 % fitresult : a fit object representing the fit.
10 % gof : structure with goodness-of fit info.
12 % See also FIT, CFIT, SFIT.
14 % Auto-generated by MATLAB on f06-Nov-2019 12:47:06
17 %% Fit: 'untitled fit 1'.
18 [xData, yData] = prepareCurveData( x, y );
20 % Set up fittype and options.
24 [fitresult, gof] = fit( xData, yData, ft, 'Normalize', 'on' );
31 figure( 'Name', 'untitled fit 1' );
32 h = plot( fitresult, xData, yData );
33 legend( h, 'l2 vs. short_time', 'untitled fit 1', 'Location', 'NorthEast' );