MLE Meixner

2 views (last 30 days)
Raphael
Raphael on 1 May 2012
Hey,
i want to estimate the meixner distribution using optimization toolbox's fminsearch.
The log-likelihood code is as follows: function lmeixner=log_mxn(x) x=x(:) n=length(x); for j=1:length(n); z(j,1)=(x(j,1)-m)./a; end; z_mean=mean(z); for i=1:length(n); lmeixner(j,1)=2*d*log(2*cos(b/2))-log(2*a*pi)-log(gamma(2*d))+b*z_mean+(1/n)*sum(log(abs(cgamma(d+1i.*z(j,1)))^2)); end;
So basically i have first estimates for a,b,d,m based on moment estimates and a vector that contains the log returns and therefore i want to use mle to get estimates for a, b, d,m!
However i always get an error message using fminsearch. Maybe there is an error in the function or i'm dealing with fminsearch falsely.
Thank you for your help!

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!