Calculate Hessian Matrix

Description

Calculatate the hessian matrix of a TSmodel at a parameter value.

Usage

1
2
3
4
    ## S3 method for class 'TSestModel'
hessian(func, x=coef(func), 
     method="Richardson", method.args=list(d=0.01, eps=1e-4, r=6, v=2),
     Shape=TSmodel(func), data=TSdata(func), ...)

Arguments

func

a TSestModel object which is used as a function mapping coefficients (parameters) to likelihood.

x

The parameter point at which the hessian is calculated.

method

string indicating the numerical approximation method.

method.args

list with arguments to method (see grad).

Shape

a TSmodel in which the parameters should be used.

data

TSdata to use in teh evaluation.

...

additional arguments passed to func.

Details

This function calculates the second derivative of the likelihood for the model at its specified parameter value using given data.

Value

a matrix of second derivative of the likelihood (Fisher Information).

See Also

hessian genD grad span

Examples

1
2
3
4
5
6
   require("dse")
   data("eg1.DSE.data.diff", package="dse")
   model <- estVARXls(TSdata( output=outputData(eg1.DSE.data.diff, series=1:2)),
                     max.lag=2)
   require("numDeriv")
   hessian(model)