<< hessian Optimisation numz0 >>

Grocer >> Optimisation > maxlik

maxlik

maximization function

CALLING SEQUENCE

[results]=maxlik(func,xarg,varargin)

PARAMETERS

Input

* func= (minus likelihood) function to minimize

* xarg= parameter vector fed to func

* argi=

  - optional arguments passed for infoz

    * 'maxit=x' to set the maximum # iterations (default 100)

    *'btol=x' to set the convergence criterium for b (default 1e-5)

    *'ftol=x' to set the convergence criterium for function (default 1.49e-8)

    *'gtol=x' to set the convergence criterium for gradiant (default 1.49e-8)

    *'dirtol=x' to set the maximum change on b authorized during an iteration (default 1)

    *'cond=x' to set the maximum condition number authorized for hessian matrix (default 1000)

    *'lambda=x' to set lambda in the GN/Marq hess option (default 0.01)

    *'delta=x' to set the increment used in the numz func (default 0.01)

    *   'optprt=0' not to print the cause of the stop (default 1)

    *   'hess=namefunc' to set the name of an hessian update function (default hessz)

    *'grad=namefunc' to set the name of a gradiant function (default numz0)

  - or: arguments (if any) other than xarg passed to func

 

Output

* results = a result list with:

  - results('meth')  = infoz(hess)

= 'dfp', 'bfgs', 'gn', 'marq', 'sd' (from input)

  - results('hess')  = numerical hessian at the optimum

  - results('bhist') = history of b at each iteration

  - results('b')     = parameter value at the optimum

  - results('f')     = objective function value at the optimum

  - results('g')     = gradient at the optimum

  - results('dg')    = change in gradient

  - results('db')    = change in b parameters

  - results('df')    = change in objective function

  - results('iter')  = # of iterations taken

  - results('time')  = time (in seconds) needed to find solution

  - results('infoz') = infoz (options used)

DESCRIPTION

Maximizes a (minus log likelihood) function func must take the form func(b,varargin) where:

b = parameter vector (k x 1)

varargin = arguments passed to the function

EXAMPLE

1) rd=maxlik('f_ssr',init,chdelta, varargin(:),chftol)
 2) oresult = maxlik('to_llike',b0,y,x,vtrunc,lopt(:))
3) oresult = maxlik('filter0',param,func,y,x,F,varargin(:))
 
These examples are taken from the functions nls, tobit and kalman. The functions maximized are f_ssr, to_llike and filter. The initial parameters are respectively init, b0 and param. In example 2 and 3, y, x and vtrunc (in example 2) or F (in example 3) are the parameters other than b0 of function to_llike. chdelta, chftol, lopt(:) are varargin(:) are options for maxlik.

AUTHOR

Eric Dubois 2002

Report an issue
<< hessian Optimisation numz0 >>