谢谢大家的回复,我生成M-file后,将有用的信息摘了出来,
rm = rmx(:);
r2 = r2y(:)
ft_ = fittype('fourier6'); %在GUI中可以设置选择fourier的方式
% Fit this model using new data
cf_ = fit(rm,r2,ft_);
% Plot this fit
h_ = plot(cf_,'fit',0.95);
set(h_(1),'Color',[1 0 0],'LineStyle','-', 'LineWidth',1,'Marker','none', 'MarkerSize',6);