[R-sig-eco] Plotting power graph for one sample proportion test

Roman Luštrik roman.lustrik at gmail.com
Thu Mar 17 09:27:19 CET 2016


Hi,

you're looking for a simulation approach of sorts. What I would do is set
up a data.frame of all combination of parameters (with e.g. `expand.grid`)
you're interested in and use for example `apply` to go through each
combination and calculate power. You save that as a new variable and plot
it.

If you can provide us with parameters and their ranges perhaps we can be of
further service.

Cheers,
Roman

On Wed, Mar 16, 2016 at 10:47 PM, Kristen Gorman <kgorman at pwssc.org> wrote:

> Dear all,
> I am looking for help in plotting a power analysis using library(pwr).
> Specifically, I am using the following test:
>
> pwr.p.test ()
>
> I would like to produce a sample size vs power plot for varying alpha
> levels and differences between the null proportion and alternative
> proportion.
>
> Thanks for any guidance,
> Kristen Gorman
>
>
>
>         [[alternative HTML version deleted]]
>
> _______________________________________________
> R-sig-ecology mailing list
> R-sig-ecology at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-ecology
>



-- 
In God we trust, all others bring data.

	[[alternative HTML version deleted]]



More information about the R-sig-ecology mailing list