size.test.prop.ps {statpsych}R Documentation

Sample size for a test of a paired-samples proportion difference

Description

Computes the sample size required to test a difference in population proportions with desired power in a paired-samples design. This function requires planning values for both proportions and a phi coefficient that describes the correlation between the two dichotomous measurements. The proportion planning values can be set to .5 for a conservatively large sample size. The planning value for the effect size (proportion difference) could be set equal to the difference of the two proportion planning values or it could be set equal to a minimally interesting effect size. Set the phi correlation planning value to the smallest value within a plausible range for a conservatively large sample size.

Usage

size.test.prop.ps(alpha, pow, p1, p2, phi, es)

Arguments

alpha

alpha level for hypothesis test

pow

desired power

p1

planning value of proportion for measurement 1

p2

planning value of proportion for measurement 2

phi

planning value of phi correlation

es

planning value of proportion difference

Value

Returns the required sample size

Examples

size.test.prop.ps(.05, .80, .4, .3, .5, .1)

# Should return:
# Sample size
#         177



[Package statpsych version 1.6.0 Index]