You can use the "fit" function from our Curve Fitting toolbox to fit a curve to your data and then use the fitted curve to sample a new set of data:
>>
>> x1 = [-50:50]';
>>y1 = x1.^2 + 200.*randn(numel(x1),1);
>>
>>
>>f = fit(x1, y1, 'poly2');
>>
>>
>>x2 = -25:25;
>>y2 = f(x2);
>>
>>figure
>>plot(x1,y1,'o')
>>hold on
>>plot(x2, y2,'x')
You can refer to the following documentation link to learn more about the "fit" function used above :
Best Answer