Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: ML-Evaluator for modelling retirement decisions


From   Gordon Hughes <[email protected]>
To   [email protected]
Subject   Re: st: ML-Evaluator for modelling retirement decisions
Date   Wed, 04 Jan 2012 11:28:40 +0000

The problem here seems to be the lack of clarity in the econometric specification that you want to use.

The way you describe your problem implies a two-stage model in which the second stage probit can be estimated using Stata's standard -probit- procedure. This method can be modified to deal with the case in which the second stage is actually maximising a concentrated likelihood function for given values of GAMMA and ALPHA with a first stage involving a grid search or iteration over GAMMA and ALPHA using the results of the second stage.

Alternatively, you may have in mind a more general model in which you want to generate ML estimates of all of the coefficients in b[]. In that case, you need to write down the full likelihood function and write the appropriate code for -ml-.

Gordon Hughes
[email protected]

=============

Im modelling retirement decisions based on an option value framework (Gruber and Wise, 2002). Up until now I have constructed a microsimulation model calculating the option value for each individual in each year. To make it short, the option value is a forward-looking variable that summarizes the future options (with regard to retirement) of an individual at a certain point in time.

Based on this approach I estimate a binary probit model with retirement in the current year as dependent variable and option value (OV), social security wealth (SSW), age and some other variables as covariates.

However, since the option value is denoted in utility terms I have to assume some exogenous parameters of the utility function. There are basically two parameters: GAMMA, which defines marginal utility of income, and ALPHA, which is a factor defining the utility gain through leisure in retirement (relative to work). Exogenous values taken from the literature would be: GAMMA=0.75 and ALPHA=1.36

As a next step I'm writing a maximum likelihood evaluator so that I can jointly estimate those two parameters together with the binary probit model. Since I wanted to keep it simple I'm using a gf0 evaluator. Also, I had to make sure that the two parameters stay whithin their ranges (0 to 1 for GAMMA and 1 to 2 for ALPHA), so I transform parameters b[1,5] (hp_alpha) and b[1,6] (hp_gamma) through the use of the normal cdf. Though my program passes ml check, it doesn't converge. In fact, it seems to be unable to go on to the next iteration (#1) though it keeps on repeating every step in the program. Here is a reduced version of the code.

program ML_OPV
args todo b lnfj
tempvar alpha gamma
quietly gen double `alpha'=1+normal(`b'[1,5])
quietly gen double `gamma'=normal(`b'[1,6])
*display "ALPHA: " `alpha'
*display "GAMMA: " `gamma'
quietly {
forvalues j=2002(1)2012 {
      * Calculate Utility from Retirement based on `alpha' and `gamma'
      < CODE OMITTED >

      * Calculate Utility from Labour Income based on `gamma'
      < CODE OMITTED >
}
* CALC. OPTION VALUE BASED ON UTILITY VALUES FOR DIFFERENT RETIREMENTAGES
< CODE OMITTED >

* DEFINE LIKELIHOOD FUNCTION
tempvar xb
gen double `xb' = `b'[1,1]*SSW + `b'[1,2]*OV + `b'[1,3]*gn_age +`b'[1,4]
replace `lnfj' = ln(normal(`xb')) if $ML_y1 == 1
replace `lnfj' = ln(normal(-1*`xb')) if $ML_y1 == 0
}
end

ml model gf0 ML_OPV (theta: GO = SSW OV gn_age) /hp_alpha /hp_gamma
ml init SSW=.000004 OV=-.0008 gn_age=.16 /hp_alpha=-.001 /hp_gamma=.5
ml max, technique(nr) trace showstep

I recognize that it might be quite hard to help me out from the distance, however, it would be greatly appreciated. Especially, I'm wondering whether my approach concerning ALPHA and GAMMA is valid or whether there is any easier way to do it.


*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index