prop1: Compute power for a single sample proportion test Takes phi,...

View source: R/prop1.R

prop1R Documentation

Compute power for a single sample proportion test Takes phi, degrees of freedom, and a range of sample sizes. Alpha is .05 by default, alternative values may be entered by user

Description

Compute power for a single sample proportion test Takes phi, degrees of freedom, and a range of sample sizes. Alpha is .05 by default, alternative values may be entered by user

Usage

prop1(p1, p0, nlow, nhigh, alpha = 0.05, tails = 2, by = 1)

Arguments

p1

expected proportion (a.k.a. alternative proportion)

p0

null proportion

nlow

starting sample size

nhigh

ending sample size

alpha

Type I error (default is .05)

tails

number of tails for test (default is 2)

by

Incremental increase in sample (e.g. nlow = 10, nhigh = 24, by = 2, produces estimates of 10, 12, and 14)

Value

Power for Tests of Single Proportion

Examples

prop1(p1=.60, p0=.42,nlow=20,nhigh=100, tails=1, by=10)

pwr2ppl documentation built on Sept. 6, 2022, 5:06 p.m.