Statalist The Stata Listserver


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: How do you test the equality of regression coefficients that are generated from two different TOBIT models, estimated on two different samples?


From   "Tim Wade" <[email protected]>
To   [email protected]
Subject   Re: st: How do you test the equality of regression coefficients that are generated from two different TOBIT models, estimated on two different samples?
Date   Sat, 21 Apr 2007 22:44:20 -0400

In my experience and understanding, I don't think it is exactly
correct that suest is approximate and that it is necessarily worse
than an interaction test with the full sample. In fact, suest gives
the exact same results as an interaction test with a robust command
when factor being stratified on (e.g., males and females) is used as
an interaction term with all X's .

In the example below I had to us an old version of suest since my home
computer only has Stata 7, but I have verified this with later
versions. Note that the tests of the coefficients for the tests of
price and gear_ratio in models A and B have the same results (p
values) as the coefficients on these interaction terms _IrepXpri,
_IrepXgea in the combined model. So I think suest could be very
valuable when you have evidence that it is important to have different
models in males and females.

However, I'm not sure why it does not work after tobit. But suest can
only work on commands where scores can be predicted in
post-estimation, maybe this is part of the problem

. use "C:\Stata\auto.dta", clear
(1978 Automobile Data)

. gen rep78_4=rep78
(5 missing values generated)

. recode rep78_4 min/3=1 4/max=0
(67 changes made)

. suest clear

/*note suest syntax for version 9 is much different*/

. suest fit A: logit foreign price  gear_ratio if rep78_4==0
logit foreign price gear_ratio if rep78_4==0  , score(SU_A)

Iteration 0:   log likelihood = -19.248039
Iteration 1:   log likelihood = -9.2095199
Iteration 2:   log likelihood = -7.5795748
Iteration 3:   log likelihood = -7.0228846
Iteration 4:   log likelihood = -6.8342956
Iteration 5:   log likelihood = -6.8078772
Iteration 6:   log likelihood = -6.8074489
Iteration 7:   log likelihood = -6.8074488

Logit estimates                                   Number of obs   =         29
                                                 LR chi2(2)      =      24.88
                                                 Prob > chi2     =     0.0000
Log likelihood = -6.8074488                       Pseudo R2       =     0.6463

------------------------------------------------------------------------------
    foreign |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
      price |   .0012338   .0008688     1.42   0.156     -.000469    .0029366
 gear_ratio |   8.862073   3.996788     2.22   0.027     1.028513    16.69563
      _cons |  -33.70932   16.10586    -2.09   0.036    -65.27622   -2.142424
------------------------------------------------------------------------------

. suest fit B: logit foreign price  gear_ratio if rep78_4==1
logit foreign price gear_ratio if rep78_4==1  , score(SU_B)

Iteration 0:   log likelihood = -10.655379
Iteration 1:   log likelihood = -7.3154717
Iteration 2:   log likelihood = -4.2136145
Iteration 3:   log likelihood = -3.4954643
Iteration 4:   log likelihood = -3.3268647
Iteration 5:   log likelihood = -3.3062563
Iteration 6:   log likelihood = -3.3055826
Iteration 7:   log likelihood = -3.3055806

Logit estimates                                   Number of obs   =         40
                                                 LR chi2(2)      =      14.70
                                                 Prob > chi2     =     0.0006
Log likelihood = -3.3055806                       Pseudo R2       =     0.6898

------------------------------------------------------------------------------
    foreign |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
      price |   .0003424   .0009001     0.38   0.704    -.0014218    .0021065
 gear_ratio |    9.80649   4.699577     2.09   0.037      .595488    19.01749
      _cons |  -35.96772   17.97924    -2.00   0.045    -71.20639   -.7290593
------------------------------------------------------------------------------

. suest combine
Simultaneous VCE                                              Obs    =      69

------------------------------------------------------------------------------
            |               Robust
            |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
A            |
      price |   .0012338   .0007007     1.76   0.078    -.0001394    .0026071
 gear_ratio |   8.862073   4.443457     1.99   0.046     .1530575    17.57109
      _cons |  -33.70932   16.14748    -2.09   0.037     -65.3578   -2.060845
-------------+----------------------------------------------------------------
B            |
      price |   .0003424   .0003364     1.02   0.309    -.0003169    .0010017
 gear_ratio |    9.80649   2.454996     3.99   0.000     4.994787    14.61819
      _cons |  -35.96772   9.296394    -3.87   0.000    -54.18832   -17.74713
------------------------------------------------------------------------------

. test [A]price=[B]price
/*test equivalence of price in two models*/
( 1)  [A]price - [B]price = 0.0

          chi2(  1) =    1.32
        Prob > chi2 =    0.2514

/*test equivalence of gear_ratio in two models*/
. test [A]gear_ratio=[B]gear_ratio

( 1)  [A]gear_ratio - [B]gear_ratio = 0.0

          chi2(  1) =    0.03
        Prob > chi2 =    0.8524


. xi: logit foreign i.rep78_4*price  i.rep78_4*gear_ratio, robust
i.rep78_4         _Irep78_4_0-1       (naturally coded; _Irep78_4_0 omitted)
i.rep78_4*price   _IrepXprice_#       (coded as above)
i.rep7~4*gear~o   _IrepXgear__#       (coded as above)

note: _Irep78_4_1 dropped due to collinearity
Iteration 0:   log likelihood = -42.400729
Iteration 1:   log likelihood = -16.503351
Iteration 2:   log likelihood = -12.292906
Iteration 3:   log likelihood = -10.715161
Iteration 4:   log likelihood = -10.209982
Iteration 5:   log likelihood = -10.120269
Iteration 6:   log likelihood = -10.113192
Iteration 7:   log likelihood =  -10.11303
Iteration 8:   log likelihood = -10.113029

Logit estimates                                   Number of obs   =         69
                                                 Wald chi2(5)    =      20.24
                                                 Prob > chi2     =     0.0011
Log likelihood = -10.113029                       Pseudo R2       =     0.7615

------------------------------------------------------------------------------
            |               Robust
    foreign |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
_Irep78_4_1 |    -2.2584   18.63235    -0.12   0.904    -38.77713    34.26033
      price |   .0012338   .0007007     1.76   0.078    -.0001394    .0026071
_IrepXpric~1 |  -.0008914   .0007772    -1.15   0.251    -.0024147    .0006319
 gear_ratio |   8.862073   4.443458     1.99   0.046     .1530558    17.57109
_IrepXgear~1 |   .9444165   5.076549     0.19   0.852    -9.005437    10.89427
      _cons |  -33.70932   16.14748    -2.09   0.037    -65.35781   -2.060839
------------------------------------------------------------------------------

.


On 4/20/07, Maarten buis <[email protected]> wrote:
--- Maria Cecilia Calderon <[email protected]> wrote:
> In addition, I can test the equality of the coefficients including
> interaction terms between the gender variable and each explanatory
> variable using the whole sample (males and females). Is there a
> difference between this procedure and the 'suest' command?

Yes, and the interactions are better. -suest- is approximate.
Hope this helps,
Maarten

-----------------------------------------
Maarten L. Buis
Department of Social Research Methodology
Vrije Universiteit Amsterdam
Boelelaan 1081
1081 HV Amsterdam
The Netherlands

visiting address:
Buitenveldertselaan 3 (Metropolitan), room Z434

+31 20 5986715

http://home.fsw.vu.nl/m.buis/
-----------------------------------------


      ___________________________________________________________
Yahoo! Mail is the world's favourite email. Don't settle for less, sign up for
your free account today http://uk.rd.yahoo.com/evt=44106/*http://uk.docs.yahoo.com/mail/winter07.html
*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   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