Wednesday, April 11, 2012

A quick appeal on power analysis

So the stata commands that put in sample sizes, group means, and standard deviation to get out power are straightforward. Likewise, puting in power, group means, and standard deviations, and getting out sample size are straightforward.

It seems like it should be trivial to put in power and sample size and maybe a baseline group mean and get out a minimum detectable effect.... but stata doesn't seem to be able to do this with anything I've been able to put my hands on. If I had more time I'd do it by hand but I don't trust myself to do that right.

Anyone familiar with power analysis to get minimum detectable effects - preferably in stata, although possibly elsewhere?


  1. I'm unfamiliar with stata, but GPower can compute the minimum effect size as a function of power and sample size (plus other information depending on the test) for many situations. See here.

    1. Thanks BR - it took a little while to get used to the lingo, but this is exactly what I needed.

      It can get me Cohen's d which - if you are willing to make some assumptions about what it is you're looking for - can get you the difference in means.


      G*plus is very user-friendly too. I'm still not sold on how useful power analyses actually are, but if anyone is interested in this sort of thing this is a fun one to play around with.

    2. Glad to help!

      I agree that power analyses are not very useful for large sample sizes: if the effect size is small enough that you need a large sample size to reliably detect it, you probably have bigger problems. It's not surprising that Cohen was a psychologist.

      Most of the situations I deal with have small enough sample sizes that a power analysis is a reasonable thing to do, but the models are complicated enough (like GLMMs or mediation analyses) that I can't use any out-of-the-box programs, at least not without sacrificing power (which is likely to not be high to begin with). So it could be worse!


All anonymous comments will be deleted. Consistent pseudonyms are fine.