Learn R Programming

ssutil (version 1.0.0)

power_single_rate: 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)

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

Arguments

subjects

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

power

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

Examples

Run this code
power_single_rate(30, 0.9)
power_single_rate(c(30, 50, 100), 0.9)

Run the code above in your browser using DataLab