# Power calculation using pwr.t.test()

3 messages
Open this post in threaded view
|
Report Content as Inappropriate

## Power calculation using pwr.t.test()

 Dear R experts, I have conducted a power calculation in order to estimate the number of subjects needed to detect an effect size of d=0.28 (cohen's d) for a difference between two independent groups (alpha level should be 0.05 and the effect should be detected with 80% probability). The results from the code below indicates that I would need n=400 subjects (200 in each group). This is seems so incredibly high that I mistrust my results & wanted to ask whether I miscalculated n? library(pwr) pwr.t.test(d=0.28,sig.level=0.05,power=0.8,type="two.sample",alternative="two.sided") Many thanks for you help! Jokel         [[alternative HTML version deleted]] ______________________________________________ [hidden email] mailing list https://stat.ethz.ch/mailman/listinfo/r-helpPLEASE do read the posting guide http://www.R-project.org/posting-guide.htmland provide commented, minimal, self-contained, reproducible code.
Open this post in threaded view
|
Report Content as Inappropriate

## Re: Power calculation using pwr.t.test()

 On 24.06.2012 17:41, Jokel Meyer wrote: > Dear R experts, > > I have conducted a power calculation in order to estimate the number of > subjects needed to detect an effect size of d=0.28 (cohen's d) for a > difference between two independent groups (alpha level should be 0.05 and > the effect should be detected with 80% probability). > The results from the code below indicates that I would need n=400 subjects > (200 in each group). This is seems so incredibly high that I mistrust my > results & wanted to ask whether I miscalculated n? > > library(pwr) > pwr.t.test(d=0.28,sig.level=0.05,power=0.8,type="two.sample",alternative="two.sided") Good luck this is an open source software where you can easily review the code and check if it is right. If it is not, I'd propose to send a patch to the package maintainer. Best, Uwe Ligges > Many thanks for you help! > Jokel > > [[alternative HTML version deleted]] > > ______________________________________________ > [hidden email] mailing list > https://stat.ethz.ch/mailman/listinfo/r-help> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html> and provide commented, minimal, self-contained, reproducible code. > ______________________________________________ [hidden email] mailing list https://stat.ethz.ch/mailman/listinfo/r-helpPLEASE do read the posting guide http://www.R-project.org/posting-guide.htmland provide commented, minimal, self-contained, reproducible code.