Stutzer index (stutzer performance ratio)

4 views (last 30 days)
DankoJones
DankoJones on 1 Aug 2012
However, i'm going somewhere detrimentally wrong
I run this matlab file, with stutzer.xls just having 5 random returns
% x0 = [0]; % Starting guess
x0=1;
returns=xlsread('stutzer.xls','Sheet1','A1:A5');
% optimopt = optimset('LargeScale','off');
% optimopt = optimset('fminsearch');
% optimopt = optimset('algorithm','interior-point');
% optimopt.MaxIter=9000000;
% optimopt.MaxFunEvals=9000000;
% optimopt.TolFun=1e-6;
% optimopt.TolX=1e-6;
% optimopt.Display='final';
% optimopt.HessUpdate='bfgs';
% optimopt.Tolcon=1e-6;
% optimopt.Diagnostics='off';
[result] = fminunc(@objfun,x0,options);
% x = fminunc(@(x) objfun(x,returns),options)
% x = fminsearch(@(x) objfun(x,returns),options)
and the OBJfun is written here;
function f = objfun(x,returns)
for i=1:5
returns=xlsread('stutzer.xls','Sheet1','A1:A5');
Omega = (-log((1/100)*(exp((x*returns(i,1))))));
Omega(:,i)=Omega;
f = sum(Omega);
end
I however do not get any results :( What am i doing wrong?
  1 Comment
Oleg Komarov
Oleg Komarov on 1 Aug 2012
Comment out the
returns=xlsread('stutzer.xls','Sheet1','A1:A5');
in objfun() function.

Sign in to comment.

Answers (0)

Community Treasure Hunt

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

Start Hunting!