Correlation and Sample Size Calculations
Correlation
Correlation assesses the association between two variables.
Pearson’s Correlation: Parametric method.
Spearman’s Correlation: Non-parametric method.
Values range from -1 to 1.
+1: Perfect positive linear association.
-1: Perfect negative linear association.
0: No linear relation.
Correlation is valid only within the sample range.
Strength of Correlation:
0 – 0.19: Very weak
0.2 – 0.39: Weak
0.4 – 0.59: Moderate
0.6 – 0.79: Strong
0.8 – 1.0: Very strong
Pearson’s Correlation Coefficient:
Measures linear association.
Does not account for curved relationships.
r > 0: Positive correlation (both variables increase).
r < 0: Negative correlation (one variable increases, the other decreases).
r = +1 or -1: Perfect straight line.
r = 0: No linear association.
Assumptions for Pearson’s Correlation:
At least one variable is normally distributed for P-value validity.
Both variables should ideally be normally distributed in practice for confidence interval validity.
All observations must be independent.
Hypothesis Test:
Null hypothesis:
Alternative hypothesis:
Test statistic: T-test
Sample Size:
The value at which the correlation coefficient becomes significant at the 5% level.
N=10, correlation=0.63
N=20, correlation=0.44
N=50, correlation=0.28
N=100, correlation=0.20
N=150, correlation=0.16
Spearman’s Correlation:
Measures general association, not just linear.
Non-parametric.
Applicable to ordinal data.
Outliers have less effect.
Presentation of Correlation:
Include graph, correlation coefficient (to 2 decimal places), P-value, and number of observations.
Example: N=20, R=0.58 (P<0.01)
Problems with Correlation:
Correlation does not imply causation.
It is useful for generating hypotheses.
Correlation does not quantify agreement.
Multiple testing issues arise when calculating numerous correlations.
Sample Size Calculations
Understanding hypothesis testing is crucial.
Understanding errors related to hypothesis testing is necessary.
Need to comprehend the power of a test.
Importance of Sample Size:
Larger studies increase power to detect differences.
Estimates population parameters with precision.
Many clinical trials are too small.
Increasing sample size increases test power.
Ethical Considerations:
Too small or too large sample sizes can be unethical.
Impacts time, manpower, risk, and cost.
Aim for the minimum sample size to achieve a high probability (power) of detecting a clinically worthwhile effect.
Objectives of Study:
Should be quantified.
Relate to a single primary outcome.
Predetermined in grant applications and study protocols.
Factors Influencing Sample Size:
Outcome type.
Number of groups for comparison.
Sampling variability.
Effect size.
Response rate.
Clinical outcome should be expressed in a patient-relevant way.
Components for Sample Size Calculation:
Effect size: The magnitude of the effect we wish to detect (clinically relevant difference).
Variability: Standard Deviation (SD) to calculate effect size.
Chosen Level of Significance: Type I error (e.g., 0.05).
Chosen Power: 1 – Type II error (e.g., 80%).
Type I and Type II Errors:
Type I Error (False Positive):
Rejecting the null hypothesis when it is true.
Risk =
Type II Error (False Negative):
Failing to reject the null hypothesis when it is false.
Risk =
Power:
The probability of rejecting a false null hypothesis.
Power =
Power of a Test:
Used to compare two tests with the same
Helps decide appropriate sample size.
Larger sample sizes generally lead to more powerful tests.
Significance Level ():
The probability of a Type I error.
Controlled by the location of the rejection or critical region.
Common values: 0.05 or 0.01.
Choosing a small may increase (Type II error).
Sample Size Calculation - Basics:
Continuous outcome scale (blood pressure, age, QoL score): compare two group means.
Binary outcome scale (yes/no, disease present/absent): compare proportions of 'yes' between two groups.
Sample Size Calculation - Advanced:
Longitudinal Studies: Account for dropouts and correlation between repeated measures.
Neuroimaging Studies: Consider multiple comparisons problem.
Genetic Studies: Sample size must be large to detect small effect sizes.
Clinical Trials: Account for the expected effect size and population variance.
Animal Studies: Balance ethical considerations with the need for statistical power.
Consult a statistician for complex scenarios.
Examples of comparing variables:
Comparing continuous variables
Comparing proportions
Sample size calculations- comparing two group means for a continuous outcome
Outcome should be on continuous scale (quality of life score, blood pressure, cholesterol level etc.)
In a trial if considered two sample t-test that means comparing two group means in continuous scale
Formula:
Where:
is the number of patients in each group.
is the standard deviation of the outcome.
is the smallest clinically important difference in the mean outcome between the groups.
is the quantile related to the hypothesis test significance level. For a 5% significance level, .
is the quantile related to the hypothesis test of power. For 90% power, .
Example Problem:
A double-blind, placebo-controlled, randomized trial investigates a statin drug's effect on LDL cholesterol levels.
Adults aged 55-70 at low stroke risk are followed for six months.
The primary outcome is LDL cholesterol level (mmol/L) at six months.
A clinically important reduction is 1.8 mmol/L.
Previous study SD is approximately 3.0 mmol/L.
Significance level of 5% and power of 90% are desired.
Solution:
s = 3
T = 1.8
Approximately 59 patients per group.
Using STATA:
power twomeans 4.5 6.3 , sd(3) power(0.9)power twomeans 14.5 16.3 , sd(3) power(0.9)power twomeans 16.3 14.5 , sd(3) power(0.9)power twomeans 5.0, diff(1.8) sd(3) power(0.9)power twomeans 15.0, diff(1.8) sd(3) power(0.9)All yield approximately n = 60 per group.
Accounting for Drop-Out Rate:
Where is the expected drop-out rate.
is the original sample size.
Then is the adjusted sample size.
If expected drop out rate is 10% in LDL trial (d=0.10):
So, calculate revised sample size after considering expected drop out rate.
Sample size calculations-comparing two proportions
Outcome should be on proportion, rate, prevalence…
In a trial if considers comparing two rates or prevalence or proportions..
Assume equal sample per group / arm of the trial
Formula:
Where
= Estimated current prevalence rate.
= Maximum prevalence rate that would signify a clinically important reduction (if interest lies in a prevalence reduction)
= , mean of and
= Quantile related to hypothesis test significance level. For a 5% significance level, = 1.96.
= Quantile related to hypothesis test of power. For 80% power, = 0.84.
Example:
Multi-center randomized trial to investigate the effect of a beta-blocker on mortality as a treatment for severe heart failure.
The trial will be double-blind, placebo controlled and will include the same number of patients in each group.
Patients will be followed for two years and the primary outcome is all-cause mortality during this two-year period.
A previous study suggests that there is a two-year mortality rate of approximately 36% amongst the population of patients to be considered.
The investigators consider that it would be clinically important to detect a reduction to 24% in two-year mortality when treated with the beta-blocker.
The investigators wish to use a significance level of 5% and a power of 80%.
Therefore, we should recruit 228 patients in each group.
Using STATA:
power twoproportions 0.24 0.36 , test(chi2) power(0.8)n= 228 / group
power twoproportions 0.24 0.36 , test(chi2) power(0.9)n= 305/ group
The more power you want to achieve the more sample you need.