[ Search |  Up Level |  Project home |  Index |  Class hierarchy ]

 MNP.ox

Multinomial Probit using FiveO.

This is an example of how to implement an econometric objective. FiveO is not designed to handle sample selection and other standard tasks for the user. However, built in features of Ox are readily available for those purposes.

 xGHKMNP : xMNP

Public fields
 ghk const
 sigfree const
 SigLT const
Public methods
 SetGHK
 vfunc Compute and return the vector of log-likelihoods at the current parameters.
 xGHKMNP GHK based objective for MNP log likelihood.
Enumerations
 Anonymous enum 1
Inherited methods from xMNP:
Estimate, SetD, xMNP
Inherited fields from xMNP:
betas, D, indY, J, Jvals, lk, namearray, NN, nX, X, Y

 xGQMNP : xMNP

Public fields
 Npts const # of nodes in quadrature
Public methods
 vfunc Compute and return the vector of log-likelihoods at the current parameters.
 xGQMNP Gauss-Hermite based objective for MNP log likelihood.
Inherited methods from xMNP:
Estimate, SetD, xMNP
Inherited fields from xMNP:
betas, D, indY, J, Jvals, lk, namearray, NN, nX, X, Y

 xMNP

Public fields
 betas const Array of J-1 parameter blocks, one for each equation except Y=0.
 D
 indY const N x J matrix of permutations
the first column is index of Y
second column is first non-Y choice
third column is second non-Y choice
etc.
 J const J : number of options
 Jvals const integer codes of choices
 lk
 namearray const Labels for variables
 NN const indexing vector
 nX const K : number of X variables
 X const X : matrix of exog variables
 Y const Y : discrete endog vector
Public methods
 Estimate Estimate the model using BHHH, print results.
 SetD
 xMNP Create a new MNP model.

 xGHKMNP

Enumerations
Anonymous enum 1 identity, onlydiag, lowertriangle, SigmaOptions

 ghk

const decl ghk [public]

 SetGHK


 sigfree

const decl sigfree [public]

 SigLT

const decl SigLT [public]

 vfunc

xGHKMNP :: vfunc ( )
Compute and return the vector of log-likelihoods at the current parameters.

 xGHKMNP

xGHKMNP :: xGHKMNP ( R , iSigma , fn , Yname , Xnames )
GHK based objective for MNP log likelihood.
Parameters:
R
iSigma
fn
Yname
Xnames

 xGQMNP

 Npts

const decl Npts [public]
# of nodes in quadrature

 vfunc

xGQMNP :: vfunc ( )
Compute and return the vector of log-likelihoods at the current parameters.

 xGQMNP

xGQMNP :: xGQMNP ( Npts , fn , Yname , Xnames )
Gauss-Hermite based objective for MNP log likelihood.
Parameters:
Npts
fn
Yname
Xnames

 xMNP

 betas

const decl betas [public]
Array of J-1 parameter blocks, one for each equation except Y=0.

 D

decl D [public]

 Estimate

xMNP :: Estimate ( )
Estimate the model using BHHH, print results.

 indY

const decl indY [public]
N x J matrix of permutations
the first column is index of Y
second column is first non-Y choice
third column is second non-Y choice
etc.

 J

const decl J [public]
J : number of options

 Jvals

const decl Jvals [public]
integer codes of choices

 lk

decl lk [public]

 namearray

const decl namearray [public]
Labels for variables

 NN

const decl NN [public]
indexing vector

 nX

const decl nX [public]
K : number of X variables

 SetD

xMNP :: SetD ( )

 X

const decl X [public]
X : matrix of exog variables

 xMNP

xMNP :: xMNP ( fn , Yname , Xnames )
Create a new MNP model.
Parameters:
fn string, a file to load the data from using Ox Database.Load()
Yname string, name or label of the column in the file that contains Y
Yname can contain any integers. MNP will translate the unique sorted values into 0...Jvals-1
Xnames a string of the form var1 var2 ... varN
Comments:
Observations with any missing data are deleted.
A constant column is appended at the end of the X matrix as in Stata.
Summary statistics are reported.

 Y

const decl Y [public]
Y : discrete endog vector