power_single_rate {ssutil}R Documentation

Detectable Event Rate with Specified Power and Sample Size

Description

Estimates the minimum true proportion of events needed to detect at least one event, given a sample size and desired statistical power.

Usage

power_single_rate(subjects, power)

Arguments

subjects

Integer or vector of integers. Sample size(s).

power

Numeric or vector of numerics. Desired power(s), between 0 and 1.

Value

A matrix of class power_single_rate with columns:

n

Sample size

power

Requested power

proportion

Minimum detectable event rate to observe at least one event

Examples

power_single_rate(30, 0.9)
power_single_rate(c(30, 50, 100), 0.9)


[Package ssutil version 1.0.0 Index]