[parameter,stdev,t_statistics,TP]=svensson_model(parameter0,bond);
??? Error using ==> optim\private\lsqncommon
User supplied function failed with the following error:
Date number out of range.
Error in ==> lsqcurvefit at 149
[x,Resnorm,FVAL,EXITFLAG,OUTPUT,LAMBDA,JACOB] = ...
Error in ==> svensson_model at 8
[parameter,resnorm,residual,exitflag,output,lambda,jacobian]=lsqcurvefit(@svensson_fun_lsq,parameter,bond,zeros(size(bond_inf,1),1),[],[],[],2);
我验证了日期并没有超过范围,不知道是两个函数中那个出了问题,各位大侠,有做过这方面的,不吝赐教!