Hello Statalist members,
I need some help on two lines of contrasts codes after fitting a repeated measures ANOVA model in my research. I'm using Stata 17. I fitted a repeated measures ANOVA model by using the following code:
where the between-subject effect is bcorpalt (two conditions) and within-subject effect is emtype (3 conditions). The sample sizes for the two conditions for bcorpalt are different at 64 obs and 50 obs, respectively.
To run some contrast tests between the two levels of bcorpalt at each conditon of emtype, I ran the following two types of code:
The results with emptycells(reweight) and with noestimcheck are different. Thus, I am not sure which one to use.
From the Stata manual, I also found that
- noestimcheck specifies that contrast not check for estimability and
- emptycells(reweight) specifies that the effects of the observed cells be increased to accommodate any missing cells. This makes the contrast estimable but changes its interpretation.
I think that I have unequal sample sizes for the two conditions of the between-subjects factor, bcorpalt, but I am not sure if I can use emptycells(reweight) in the contrast code to accomodate any missing cells. Since the results with and without "emptycells(reweight)" are different, I want to make sure I use the appropriate code.
Thanks for your help in advance.
I need some help on two lines of contrasts codes after fitting a repeated measures ANOVA model in my research. I'm using Stata 17. I fitted a repeated measures ANOVA model by using the following code:
Code:
anova em bcorpalt / id|bcorpalt emtype bcorpalt#emtype, repeated(emtype)
To run some contrast tests between the two levels of bcorpalt at each conditon of emtype, I ran the following two types of code:
Code:
contrast ar.bcorpalt@emtype, emptycells(reweight) effects mcompare()
Code:
contrast ar.bcorpalt@emtype, noestimcheck effects mcompare()
From the Stata manual, I also found that
- noestimcheck specifies that contrast not check for estimability and
- emptycells(reweight) specifies that the effects of the observed cells be increased to accommodate any missing cells. This makes the contrast estimable but changes its interpretation.
I think that I have unequal sample sizes for the two conditions of the between-subjects factor, bcorpalt, but I am not sure if I can use emptycells(reweight) in the contrast code to accomodate any missing cells. Since the results with and without "emptycells(reweight)" are different, I want to make sure I use the appropriate code.
Thanks for your help in advance.