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: RE: RE: Treatment effect not produced when running psmatch2 on STATA 12


From   Rekha Varghese <[email protected]>
To   "[email protected]" <[email protected]>
Subject   RE: st: RE: RE: Treatment effect not produced when running psmatch2 on STATA 12
Date   Wed, 3 Jul 2013 18:45:08 +0000

Nick,

Thanks to you, our problem is solved. We thought we had removed all the previous versions of psmatch2 from our shared server, but that turned out not to be the case. 

Rekha

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Nick Cox
Sent: Wednesday, July 03, 2013 11:18 AM
To: [email protected]
Subject: Re: st: RE: RE: Treatment effect not produced when running psmatch2 on STATA 12

I don't know what the precise difficulties are here, but I have a guess.

Usually it is most unlikely that the version of Stata is crucial for user-written software. When that bites it most often just means that something won't run because the commands are not defined for an older version of Stata, but that clearly is not the problem here.

In this case, however, I note that -ml- was rewritten for Stata 11.
The consequence can be small differences for models that are hard to estimate in terms of fits for Stata 10 and Stata 11+.

The other mundane possibility is that different people are running different versions of -psmatch2-. Everyone should check by

. which psmatch2, all

(The last checks for a common little problem, different versions of the same program on the same machine.)

Propensity scores aren't my thing at all -- I took Herbology instead
-- so others may have much better comments.

Nick
[email protected]


On 3 July 2013 15:37, Rekha Varghese <[email protected]> wrote:

> Thanks. That helped.
>
> I am showing the entire output. Two others in our office, using different datasets, also ran into the same problem, though when one of them tried it on Stata 10 at home it worked. Hence, the question about Stata 12. Since you do not have the same problem with Stata 12, maybe it is something internal to our firm's software.
>
> Reg. statalist etiquette: Will be more careful next time!

Radwin, David

> I don't seem to have the same problem using -psmatch2- in Stata 12. Are you showing the entire output?
>
> The silly example below implies that union membership has a treatment effect on the treated (ATT) of increasing hourly wages by $.89.
>
> Please note that the FAQ asks you to mention authors and locations of user-written programs (-psmatch2- is by Edwin Leuven and Barbara Sianesi and is available from SSC) and not to spell Stata in all capital letters.


> . sysuse nlsw88
> (NLSW, 1988 extract)
>
> . psmatch2 union age tenure grade south, outcome(wage) logit common
>
> Logistic regression                               Number of obs   =       1866
>                                                   LR chi2(4)      =      79.94
>                                                   Prob > chi2     =     0.0000
> Log likelihood =  -1001.027                       Pseudo R2       =     0.0384
>
> ------------------------------------------------------------------------------
>        union |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
> -------------+--------------------------------------------------------
> -------------+--
> -------------+------
>          age |   .0033413    .018228     0.18   0.855    -.0323849    .0390676
>       tenure |   .0471613   .0093689     5.03   0.000     .0287986    .0655241
>        grade |    .063582   .0221642     2.87   0.004     .0201409    .1070231
>        south |  -.6947927   .1166248    -5.96   0.000    -.9233732   -.4662123
>        _cons |   -2.16279   .7826216    -2.76   0.006      -3.6967   -.6288799
> ----------------------------------------------------------------------
> -------- There are observations with identical propensity score 
> values.
> The sort order of the data could affect your results.
> Make sure that the sort order is random before calling psmatch2.
> ----------------------------------------------------------------------------------------
>         Variable     Sample |    Treated     Controls   Difference         S.E.   T-stat
> ----------------------------+-----------------------------------------
> ----------------------------+--
> ----------------------------+----------------
>             wage  Unmatched | 8.68811142   7.22912785   1.45898357    .22164775     6.58
>                         ATT | 8.68626376   7.80088291    .88538085   .302022285     2.93
> ----------------------------+-----------------------------------------
> ----------------------------+--
> ----------------------------+----------------
> Note: S.E. does not take into account that the propensity score is estimated.
>
>  psmatch2: |   psmatch2: Common
>  Treatment |        support
> assignment | Off suppo  On suppor |     Total
> -----------+----------------------+----------
>  Untreated |         0      1,407 |     1,407
>    Treated |         2        457 |       459
> -----------+----------------------+----------
>      Total |         2      1,864 |     1,866

Rekha Varghese
>
>> When I used psamtch2 on STATA 12, I get the logit regression to run.
>> But the treatment effect is not automatically generated with it. The 
>> following is the command and output. Is this a STATA 12 issue? Any 
>> suggestions on how to get the treatment effects to be produced 
>> automatically using the
>> psmatch2 command? Thanks,
>>
>>
>> psmatch2 cctp_treat bdtot admtot vem voth gov_nonfed for_profit rural 
>> teach_h ospital percent_medicare percent_medicaid cmi penalty_3025,
>> out(fake_outcome1)
>> logit common
>>
>> Logistic regression                               Number of obs   =
>> 1537
>>                                                   LR chi2(12)     =
>> 49.23
>>                                                   Prob > chi2     =
>> 0.0000
>> Log likelihood = -902.02616                       Pseudo R2       =
>> 0.0266
>>
>> ---------------------------------------------------------------------
>> -
>> ----
>> ----
>>   cctp_treat |      Coef.   Std. Err.      z    P>|z|     [95% Conf.
>> Interval]
>> -------------+-------------------------------------------------------
>> -------------+-
>> -------------+----
>> ----
>>        bdtot |  -.0003375   .0007795    -0.43   0.665    -.0018653
>> .0011903
>>       admtot |   .0000136   .0000175     0.78   0.435    -.0000206
>> .0000479
>>          vem |   1.05e-06   3.02e-06     0.35   0.729    -4.88e-06
>> 6.97e-06
>>         voth |  -4.83e-08   3.22e-07    -0.15   0.881    -6.78e-07
>> 5.82e-07
>>   gov_nonfed |   .0583013   .1816423     0.32   0.748    -.2977111
>> .4143137
>>   for_profit |   -.353263   .1662154    -2.13   0.034    -.6790392   -
>> .0274868
>>        rural |  -.5794989    .269043    -2.15   0.031    -1.106813   -
>> .0521843
>> teach_hosp~l |   .1910294   .1522697     1.25   0.210    -.1074136
>> .4894725
>> percent_me~e |   .0176805   .0070849     2.50   0.013     .0037944
>> .0315666
>> percent_me~d |    .009975    .007018     1.42   0.155      -.00378
>> .02373
>>          cmi |   .5187269   .2819726     1.84   0.066    -.0339292
>> 1.071383
>> penalty_3025 |   .3618394   .1409491     2.57   0.010     .0855842
>> .6380947
>>        _cons |  -3.029929   .6463519    -4.69   0.000    -4.296755   -
>> 1.763102
>> ---------------------------------------------------------------------
>> -

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

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


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