What is the rationale behind having both the delta and sd parameters for
the power.t.test function? For the relevant noncentrality parameter, we only need the ratio delta/sd. If my effect size is given as Cohen's d, then I only got that ratio and not sd. As far as I see, in such a case, I can specify delta=d and leave sd at its default value 1. Is this correct or am I missing something? Thanks. ______________________________________________ [hidden email] mailing list -- To UNSUBSCRIBE and more, see 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. signature.asc (847 bytes) Download Attachment |
> On Dec 14, 2017, at 2:26 PM, Lasse Kliemann <[hidden email]> wrote: > > What is the rationale behind having both the delta and sd parameters for > the power.t.test function? One is the standard deviation of the hypothesized data (or pooled sd in the case of two sample) under the "alternative" and one is the mean of that data (or equivalently the differences if this is a two-sample test). > For the relevant noncentrality parameter, we > only need the ratio delta/sd. If my effect size is given as Cohen's d, > then I only got that ratio and not sd. > If the data has been "standardized", then Cohen's d could be given to the function as the value for delta since the sd default is 1. > As far as I see, in such a case, I can specify delta=d and leave sd at > its default value 1. Is this correct or am I missing something? > Actually it sounds as though we are missing something. The power.t.test function makes no mention of Cohen's d or effect size. Is this question in response to a homework assignment about which we have not been informed? Further questions should have some actual R code to make this an on-topic discussion for Rhelp. > Thanks. > ______________________________________________ > [hidden email] mailing list -- To UNSUBSCRIBE and more, see > 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. David Winsemius Alameda, CA, USA 'Any technology distinguishable from magic is insufficiently advanced.' -Gehm's Corollary to Clarke's Third Law ______________________________________________ [hidden email] mailing list -- To UNSUBSCRIBE and more, see 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. |
In reply to this post by lasse.kliemann
Lasse Kliemann <[hidden email]> writes:
> What is the rationale behind having both the delta and sd parameters for > the power.t.test function? For the relevant noncentrality parameter, we > only need the ratio delta/sd. If my effect size is given as Cohen's d, > then I only got that ratio and not sd. > > As far as I see, in such a case, I can specify delta=d and leave sd at > its default value 1. Looking at the code in src/library/stats/R/power.R has clarified this for me. The only spots were a given value of sd is actually used is (1) in the computation of the ncp, where we have sqrt(n/tsample) * delta/sd, so only the ratio delta/sd counts; (2) when delta is to be computed, then sd is used for the interval given to uniroot, namely sd * c(1e-7, 1e+7), which I guess is a heuristic to cover all the plausible values. So, yes, Cohen's d can be passed as delta=d when sd=1 is maintained. Maybe a comment on this in the documentation would be helpful. (For example, the pwr package https://CRAN.R-project.org/package=pwr already mentions Cohen's d, but that package is non-standard and unfortunately not even contained in the Debian repositories. So it can make sense to stick with the standard power.t.test as far as possible.) ______________________________________________ [hidden email] mailing list -- To UNSUBSCRIBE and more, see 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. signature.asc (847 bytes) Download Attachment |
Free forum by Nabble | Edit this page |