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: Using sampling/probability weights for mixed design ANOVA in STATA


From   Steven Samuels <[email protected]>
To   [email protected]
Subject   Re: st: Using sampling/probability weights for mixed design ANOVA in STATA
Date   Thu, 16 Jun 2011 06:51:29 -0400

Meg-


I have to apologize for criticizing your response rate.  I have seen studies that had much lower rates despite strong recruitment efforts.  I really know nothing of what you tried and 25% might be as good as it could get.   

If response-weighted estimates are similar to the probability weighted estimates, you are  probably better off using the latter.  The reason is that response-weighting often leads to greater variation in the weights (larger CVs) and this can increase standard errors enough to offset the possible minimal reduction in bias. 


The second -regress- statement might be more understandable as:

regress brainvol  i.time i.sex i.hemisphere ///
                  i.time#i.sex i.time#i.hemisphere  i.sex#i.hemisphere ///
                  [pweight=yourweight], vce(cluster subject)

You could also add the three-way interaction i.sex#i.time#i.interaction to the above regression.

But the three-way model is most parsimoniously written as:
regress brainvol i.time##i.sex##i.interaction [pweight= yourweight], vce(cluster subject)

Steve
[email protected]

Meg-

To answer your question, Example 17 in the Stata Manual entry for -anova- shows a repeated measures design with two within-subject factors.

But on further consideration, I don't think you will be able to emulate the -anova- calculations with -regress-, as you would have to calculated weighted mean squares, which are not available in the regression results.  Moreover, -anova- relies on assumptions, such as the absence of certain interactions, which might not be reasonable.  

Since you have 110 subjects, you can still use -regress- directly and analyze hemisphere and time as within-subject effects. I should have realized this sooner, and I apologize..  Create a hemisphere variable coded 1 & 2.  (Strings for won't work for -regress-.)

Here is the code:

****************************
/* Main Effects */
regress brainvol  i.time i.sex i.hemisphere ///
 [pweight = yourweight], vce(cluster subject)   
/* Interactions */
regress brainvol i.time##i.sex i.time##i.hemisphere i.sex##i.hemisphere ///
 [pweight = yourweight], vce(cluster subject)  // interactions
*************************** 

With the vce(cluster subject) option, -regress- will correctly identify time and hemisphere as within-subject factors

To compare to -anova- run the above without the [pweight=] option.

This approach ignores variability imposed by the sampling design and so from a sampling standpoint the standard errors will be incorrect. You can get an idea of how incorrect, by substituting "postcode" for "subject" in the vce() option.  

Now the warning:  If you do not correct your probability weights for non-participation, you risk serious bias, except under conditions which cannot be tested.   You would be better off using no weights at all.  If you do not make such a correction, then whether you use probability weights or not, you will have to state that the children are not representative.



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