I am having a hard time doing this on Stata. I have a group of 32 students. All perform a pretest and are scored. Next, half of them are randomized to receiving an intervention and the other half don't receive it. Next, all are brought back after 1 week to perform a post-test and are scored.

I know that it is wrong to compare post-test scores with a t-test between intervention and control groups. Apparently I have to do this with "adjusting for baseline" and online I think this has to do with an ANCOVA approach.

Can someone please assist me with getting the code? I'm not sure how to do this. Thank you!


1 Answer 1


This is a really great resource that will help you take you through deciding which test to use and how to execute the code:


Outside of your question, I think you might be looking for a repeated measures design, like a repeated measures or mixed AVOVA. If the pre-test is measuring the 'same thing' as the post-test, I think that would fit one of those approaches better. If, on the other hand, the pre-test is measuring an separate variable to control for in a later analysis, another approach might be appropriate.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.