Sample Size Calculations for Two Independent Proportions Study Notes
Sample Size Calculations for Two Independent Proportions
Overview of Sample Size Determination
Objective: Calculate sample sizes, denoted as $n1$ and $n2$, needed to detect a difference of interest between two groups with a specified power of detection.
Steps to Calculate Sample Size
Define Proportions: Determine the proportions that are expected under the alternative hypothesis, :
Determine Power: Decide on the desired power for detecting the alternative hypothesis, often set as 0.80 (80%). This reflects the probability of correctly rejecting the null hypothesis when it is false.
Compute Sample Size: Utilize a statistical formula or a calculator for sample size calculation, factoring in the known effect size, denoted as .
Example 1: Sample Size Calculation for PrEP Study
Study Design: This study compares 2-year rates of HIV positive infection in high-risk populations (such as sex workers) in Mozambique.
Group 1: HIV prevention counseling.
Group 2: Pre-exposure prophylaxis treatment (PrEP).
Research Objective: Determine the sample size required to have 80% power to detect differences between infection rates where:
(expected proportion for Group 1)
(expected proportion for Group 2)
Calculating Sample Size for PrEP Study
Z-Values:
(for a two-tailed test with significance level $ ext{α} = 0.05$)
z_{1-eta} = 0.84 (for desired power of 80% or 0.80)
Effect Size Calculation: The effect size () is computed based on the proportions, and a total sample size formula is applied.
Total Sample Size: The research requires a total of participants to achieve the desired statistical power.
G*Power Calculations for Two Independent Proportions (Z-Test)
Software Configuration:
Test Family: z tests
Statistical Test: Proportions: Difference between two independent proportions
Type of Power Analysis: A priori to compute required sample size
Tails: Two-tailed test
α Error Probability: Set at 0.05
Power: Set at 0.80
Proportion p2: Set at 0.05
Proportion p1: Set at 0.15
Allocation Ratio (N2/N1): Set at 1 (equal allocation)
Outcome Calculation: The setup confirms that the total sample size required equals participants.
G*Power Calculations for Two Independent Proportions (Exact Test)
Software Configuration:
Test Family: Exact tests
Statistical Test: Proportions: Inequality, two independent groups (using Fisher’s exact test)
Type of Power Analysis: A priori to compute required sample size
Tails: Two-tailed test
α Error Probability: Set at 0.05
Power: Set at 0.80
Proportion p1: Set at 0.15
Proportion p2: Set at 0.05
Allocation Ratio (N2/N1): Set at 1 (equal allocation)
Outcome Calculation: Analysis indicates that a total sample size of participants is necessary when using Fisher’s exact test for the proportions.
Exercise on Statistical Power
Definition of Statistical Power: The power of a study is the probability that it will correctly reject a false null hypothesis. It is the likelihood of detecting an effect, given that there is one.
Relationships:
Power, Sample Size, and Effect Size are interrelated, with the following relationships:
As sample size increases, power increases (assuming the effect size and alpha level are constant).
As effect size increases, power increases (given a constant sample size and alpha level).
Formulas to demonstrate power calculation in hypothesis tests can be employed for better understanding; one could reference any hypothesis test discussed within the coursework.
Power Calculation Formulas:
For various hypothesis tests, the power calculation can yield insights into how adjustments in sample size, alpha levels, or effect sizes can affect the outcomes of the study.