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]

st: AW: adjust vs. margins revisited


From   "Martin Weiss" <[email protected]>
To   <[email protected]>
Subject   st: AW: adjust vs. margins revisited
Date   Fri, 30 Jul 2010 18:23:16 +0200

<> 

At the German UGM in June, during "Wishes and Grumbles", I requested a table
providing a one-to-one mapping between the old -adjust- syntax and the new
-margins- syntax to give credence to the assertion in the (version 11.1)
help for -adjust- that 

"...the margins command can do everything that adjust did and more". So
let`s hope it will materialise...





HTH
Martin

-----Ursprüngliche Nachricht-----
Von: [email protected]
[mailto:[email protected]] Im Auftrag von Tim Wade
Gesendet: Freitag, 30. Juli 2010 18:08
An: [email protected]
Betreff: st: adjust vs. margins revisited

Hello Statalisters:

Having recently upgradted to v. 11, I have been testing  -margins-
and, like others have discussed on Statalist, I am trying to reconcile
some results compared to the old -adjust-

Here is a simplified example


sysuse auto.dta
logistic foreign  price mpg weight
adjust price=4000 mpg weight, pr ci
margins, atmeans at(price=4000)

produces the following:


. adjust price=4000 mpg weight, pr ci

----------------------------------------------------------------------------
-------------------------------------------------------------
     Dependent variable: foreign     Equation: foreign     Command: logistic
 Covariates set to mean: mpg = 21.297297, weight = 3019.4595
 Covariate set to value: price = 4000
----------------------------------------------------------------------------
-------------------------------------------------------------

----------------------------------------------
      All |         pr          lb          ub
----------+-----------------------------------
          |    .005861    [.000219    .137016]
----------------------------------------------
     Key:  pr         =  Probability
           [lb , ub]  =  [95% Confidence Interval]


. margins, atmeans at(price=4000)

Adjusted predictions                              Number of obs   =
74
Model VCE    : OIM

Expression   : Pr(foreign), predict()
at           : price           =        4000
               mpg             =     21.2973 (mean)
               weight          =    3019.459 (mean)

----------------------------------------------------------------------------
--
             |            Delta-method
             |     Margin   Std. Err.      z    P>|z|     [95% Conf.
Interval]
-------------+--------------------------------------------------------------
--
       _cons |   .0058613   .0097907     0.60   0.549    -.0133281
.0250508
----------------------------------------------------------------------------
--


I read the previous postings by Stata Corp's  Jeff Pitlblado
(http://www.stata.com/statalist/archive/2009-11/msg00199.html where he
stated:

"The -pr- confidence intervals from -adjust- are computed by transforming
the
end-points of the CI limits from the linear prediction.

-margins- computes the CI limits using the normal approximation is valid."

but here margins produces negative confidence bounds on a probability
and also produces quite different results from -adjust-, which seems
to provide reasonable results. It does not seem plausible that both
results could be considered valid. Any thoughts?

Kind regards, Tim
*
*   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/


*
*   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