Statalist


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

RE: st: loglikelihood and loglikelihood ratio


From   Kit Baum <[email protected]>
To   [email protected]
Subject   RE: st: loglikelihood and loglikelihood ratio
Date   Wed, 18 Mar 2009 07:08:12 -0400

<>
Using a LRT, one can only compare models with the same dependent variable (that is, the same observations, not just the same variable name). You apparently are comparing the LLF values of one subset with that of the whole sample. That makes no sense, as you cannot derive the model in the subset as a restricted version of the model for the whole sample. LRTs work the same as Wald "subset F" tests of the sort performed by -test-. They cannot be used to compare models fit over different observations.


Kit Baum   |   Boston College Economics and DIW Berlin   |   http://ideas.repec.org/e/pba1.html
An Introduction to Stata Programming   |   http://www.stata-press.com/books/isp.html
An Introduction to Modern Econometrics Using Stata   |   http://www.stata-press.com/books/imeus.html



On Mar 18, 2009, at 02:33 , Jingjjing wrote:


My total dataset contains 7 regions. The estimation results for the 7
regions are fine. All R square are positive, all LR chi() are
positive, and all degree of freedom are right.



2. I choose the last 4 regions of the total 7regions and create a new
data set(changed the dummy variables).

Here, all the R square are positive, all LR chi() are positive. But
the degree of freedom are strange.

4 regions Unrestricted
- ----------------------------------------------------------------------
Equation          Obs  Parms        RMSE    "R-sq"       chi2        P
- ----------------------------------------------------------------------
lnc                72     40    .0987079    0.9693   7.62e+07   0.0000
sl                 72      8    .0230819    0.3033     417.70   0.0000
se                 72      8    .0023162    0.9399    1246.72   0.0000
sm                 72      8    .0292372    0.5744    1094.54   0.0000
- ----------------------------------------------------------------------
 _cons in equation lnc are dropped, no other variable droped


4 regions Restricted

- ----------------------------------------------------------------------
Equation          Obs  Parms        RMSE    "R-sq"       chi2        P
- ----------------------------------------------------------------------
lnc                72     37    .0930231    0.9727   1.47e+07   0.0000
sl                 72      7    .0195899    0.4982     347.11   0.0000
se                 72      7    .0022661    0.9425    1275.65   0.0000
sm                 72      7    .0270912    0.6346    1003.91   0.0000
- ----------------------------------------------------------------------
No _cons dropped, no variable dropped

Likelihood-ratio test LR chi2(2) = 6.71 (Assumption: B nested in A) Prob > chi2 = 0.0350

I am thinking if the degree of freedom changed from 3 to 2 because of
_cons in unrestricted model is dropped, but kept in restricted model?


3. I chose the first 3 regions and created them as a new dataset
(changed the dummy variables). When I estimated equations lnc, sl, sm,
se, there are two negative R square values. So I changed them to ln,
sl, sk, se and got one negative R-sq this time. LR chi() here are
negative.

*
*   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–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index