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: margins after split-plot anova


From   "Airey, David C" <[email protected]>
To   "[email protected]" <[email protected]>
Subject   re: st: margins after split-plot anova
Date   Sat, 23 Jun 2012 12:21:29 -0500

.

After skimming some books online I don't have full access to, like Analysis of Messy
Data Vol 3: Analysis of Covariance, it seems the problem with covariates in split plots 
is that the covariate could be measured at any of the different experimental units, 
and that has to be taken into account to get the model needed. The models are different
when the covariate is measured at different experimental units (plot or subplot).

What is not clear to me is how you could specify at what level the covariate is measured 
when you use the anova command in Stata. The alternative Stata command for mixed models is 
the xtmixed command, where covariates are explicitly specified at different levels in the 
syntax. You also get advantages of different correlations between units with that command.

-Dave

> Thank you. 
> In the following example the option at() does not work (not estimable): 
> 
> anova depvar c.IQ group / id|group label label#group label#c.IQ , repeated (label) 
> margins, within(group) at( IQ=(1))
> 
> There is something about having a continuous covariate in the anova model that I’m missing or that does not work in Stata. 
> 
> Let’s look at the following examples: 
> - no continuous covariate: 
> 1) anova depvar group / id|group label label#group, repeated (label) 
> margins, within(group)
> 
> 2) regress depvar group label label#group 
> margins group
> 
> - with continuous covariate: 
> 3) anova depvar c.IQ group / id|group label label#group label#c.IQ , repeated (label) 
> margins, within(group)
> 
> 4)regress depvar c.IQ group label label#group label#c.IQ 
> margins group
> 
> 
> The output of margins in 1), 2), AND 3) are equal. The output of 4) is (correctly) different from 1) and 2), because 4) includes a continuous covariate that is not present in 1) and 2). 
> And the problem (again, perhaps I’m missing something simple, but I don’t know what) is that the outcome of margins in 3) is equal to the outcome of margins in 1) and 2). 
> 
> Thank you again for any help anybody can provide. 
> Luca


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