Statalist


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

Re: st: CI for adjusted mean


From   Rachele Capocchi <[email protected]>
To   [email protected]
Subject   Re: st: CI for adjusted mean
Date   Thu, 25 Oct 2007 12:27:16 +0200

Thanks Maarten now I understood how I can resolve my problem, with regress it does work.

In the meantime I tried the predict command after anova and I have obtained the some results compare to regress, so maybe it could be correct.

. anova mpg rep78 wei, continuous( wei)
. predict mean, xb
. summ mean

Thanks a lot, without your answers I could not continue my work !

Have a nice day,
Rachele

Rachele Capocchi
Agenzia Regionale Sanit� Toscana
"U.O. Centro Statistico Elaborazione Dati"
Sede Operativa - viale Milton,7
50134 Firenze
Tel. 055-4624354
Fax. 055-4624345


Maarten buis ha scritto:

--- Rachele Capocchi <[email protected]> wrote:

I tried tried:

. adjust wei, by(rep) se ci

and I obtained the adjusted means of the groups, but I don't know how
I can obtain the overall mean.
sysuse auto, clear
recode rep78 1/2 = 3
xi: reg mpg i.rep78 wei
adjust wei, se ci
adjust wei, se ci by(rep78)

The problem was that anova turned rep78 into a series of dummies, but
did not leave those dummies behind after it finished. Th variables that
aren't mentioned anywhere in the -adjust- command are left as is, but
if they no longer exist Stata doesn't know what to do and reports
nothing. So doing all this explicitly in -regress-, the variables are
left behind, and -adjust- has no problems. Notice that -regress- and -anova- are in many cases completely equivalent, so nothing is lost by
moving from -anova- to -regress-.

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


___________________________________________________________ Want ideas for reducing your carbon footprint? Visit Yahoo! For Good http://uk.promotions.yahoo.com/forgood/environment.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