Dear All,
I am trying estimate 15 parameters using the following function: Parameters are x(1), x(2) ….. x(15)
function F = myfun(x,y,X) F=(y - (1 + x(1)*(x(2)/0.0025662))*X(:,1) - (x(2)/x(3))*(sqrt(1-x(1)^2))*X(:,2) ... - x( 4)*X(:, 3) - x(5)*X(:, 4)) - x( 6)*X(:, 5) - x( 7)*X(:, 6) - x(8)*X(:,7) ... - x( 9)*X(:, 8) - x(10)*X(:, 9) - x(11)*X(:,10) - x(12)*X(:,11) ... - x(13)*X(:,12) - x(14)*X(:,13) - x(15)*X(:,14);end
X is a matrix with 18026 rows and 14 columns y is the dependent variable with 18026 rows and 1 column
I have 15 parameters to estimate and their starting values are defined by xstart (1 row by 15 columns)
When I specify x = nlinfit(X,y,myfun,xstart) in Matlab
I get the following error: Not enough input arguments.
Could you help and let me know how to change the specification?
best, Srinivasan
Best Answer