Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Generalised residuals from tobit model left-censored at 1

    Based on Wooldridge (2014, p.231) I calculate the generalised residuals for a tobit model as follows in Stata:

    gen GR = -sigma * (y == 0) * normalden(-fitted)/normal(-fitted) + (y > 0) * (y - fitted)
    (with 'y' the truncated variable and 'fitted' the predictions derived from postestimation)

    My question is: if the model is left-censored at 1 instead of 0, do we need to replace the y == 0 and y > 0 in the formula with y == 1 and y > 1? Or does the formula for the generalised residuals remain the same, irrespective of the censoring?

    Paper to which I refer:
    Wooldridge, J. M. (2014). Quasi-maximum likelihood estimation and testing for nonlinear models with endogenous explanatory variables. Journal of Econometrics, 182(1), 226-234. https://doi.org/https://doi.org/10.1...om.2014.04.020

  • #2
    Just let Stata generate the generalized residuals for you.

    Code:
    tobit ...
    predict gres1 gres1se, scores
    In any case, you have \(\text{-fitted}\) because you assume that the lower censoring limit is at 0. Otherwise, it should be \(\text{lower limit - fitted}\).

    Code:
    webuse mroz87, clear
    tobit whrs75 nwinc wedyrs wexper c.wexper#c.wexper wifeage kl6 k618, ll(0)
    *STATA'S COMPUTATION
    predict double gres1 gres1sc, scores
    
    *BY HAND
    predict fitted, xb
    gen lambda= normalden((0-fitted)/_b[/var(e.whrs75)])/normal((0-fitted)/_b[/var(e.whrs75)])
    gen double gres2= cond(whrs75>0, (whrs75-fitted)/_b[/var(e.whrs75)], -lambda)
    Res.:

    Code:
    . l gres1 gres2 in 1/10, sep(0)
    
         +-------------------------+
         |      gres1        gres2 |
         |-------------------------|
      1. |  .00073997    .00073997 |
      2. |  .00075318    .00075318 |
      3. |  .00114851    .00114851 |
      4. | -.00019141   -.00019141 |
      5. |  .00113925    .00113925 |
      6. |  .00064512    .00064512 |
      7. |  .00007054    .00007054 |
      8. | -.00015908   -.00015908 |
      9. |   .0001887     .0001887 |
     10. | -4.491e-06   -4.491e-06 |
         +-------------------------+
    Last edited by Andrew Musau; 24 Oct 2023, 07:53.

    Comment


    • #3
      This makes a lot of sense. Thank you!

      Comment

      Working...
      X