Why Power Depends on Both Samples
In a two-sample Mendelian randomization (MR) study, the genetic association with the exposure is estimated in one sample and the association with the outcome in another. The Wald ratio combines these estimates. Its precision therefore depends on both samples: a large outcome GWAS cannot fully compensate for a very imprecise exposure association, and the reverse is also true. Allele frequency matters because it determines how much variation in genotype is available; the size of the genetic effect on the exposure matters because a stronger association makes the ratio more precise.
Power calculations are useful before data collection or when comparing proposed designs. They quantify the chance of rejecting a specified null hypothesis under a stated model and effect size. They do not determine whether the instrument assumptions are true. The calculation below concerns a single genetic instrument and a continuous exposure and outcome, using a normal approximation for the summary-data Wald ratio.
For clarity, the worked calculations use phenotypes standardized to have residual variance 1, so \(\sigma_X^2=\sigma_Y^2=1\). Then \(\beta_{GX}\) is in exposure standard deviations per effect allele, \(\theta\) is in outcome standard deviations per exposure standard deviation, and the Wald ratio is in outcome standard deviations per exposure standard deviation. If phenotypes are not standardized, retain their residual variances and use effect sizes in matching units.
Approximate Variance and Power
Let \(\hat\beta_{GX}\) and \(\hat\beta_{GY}\) be the estimated genetic associations, and let \(\hat\theta=\hat\beta_{GY}/\hat\beta_{GX}\) be the summary-data Wald ratio. In a linear association model with the assumptions above, the approximate sampling variances of the two association estimates are
The delta method gives an approximate variance for a differentiable function of estimated quantities by linearizing that function around their true values. For the ratio \(g(a,b)=b/a\), the derivatives are \(-b/a^2\) and \(1/a\). Evaluated at \(a=\beta_{GX}\) and \(b=\beta_{GY}=\theta\beta_{GX}\), the derivatives are \(-\theta/\beta_{GX}\) and \(1/\beta_{GX}\). Because the two samples are independent, the covariance between the association estimates is zero. Thus:
This approximation treats the true associations as the expansion point and is most useful when the exposure association is estimated precisely enough that the ratio is well behaved. It is not a substitute for an appropriate analysis when the instrument is very weak. The earlier material on instrument strength and the F statistic describes a related strength diagnostic; the power calculation also needs the outcome sample size and the effect being targeted.
The ratio \(|\theta|/SE\) is the signal measured in standard-error units. The first term in the power expression is usually the main contribution when the signal points toward the specified nonzero effect; the second accounts for rejection in the opposite tail. For a target power \(1-\beta\), a convenient planning approximation is
This threshold approximation uses the normal critical value and is especially convenient for solving for a sample size. A final design should be checked with the full two-tailed power expression, particularly when power is modest or the design is near its target.
Worked Example: Power From Two Equal-Sized Samples
Suppose a hypothetical study has \(N_X=N_Y=100{,}000\), effect-allele frequency \(f=0.30\), and exposure association \(\beta_{GX}=0.05\) exposure standard deviations per allele. The target causal effect is \(\theta=0.20\) outcome standard deviations per exposure standard deviation. Assume both residual variances are 1, samples are independent, and the test is two-sided with \(\alpha=0.05\).
First, the genotype variance is \(2f(1-f)=2(0.30)(0.70)=0.42\). Substituting into the ratio-variance formula gives
Therefore \(SE=\sqrt{0.00990476}=0.09952\), and the signal is \(|\theta|/SE=0.20/0.09952=2.010\). At the 5% two-sided level, \(z_{0.975}=1.960\). The approximate power is
Thus, under the stated model and target effect, power is about 52%. The result is not a statement that the causal effect is likely to be present; it is the rejection probability if the specified effect and model are correct.
Solving for a Required Sample Size
A sample-size calculation rearranges the same variance expression. With both traits standardized, define \(V_G=2f(1-f)\). For target power \(1-\beta\), set \(K=z_{1-\alpha/2}+z_{1-\beta}\). The approximate target condition is
This equation makes an important design constraint visible: the contribution from the outcome sample is \(1/N_Y\), and the contribution from the exposure sample is \(\theta^2/N_X\). If one sample size is fixed, subtract its contribution from the allowable variance before solving for the other. If the remaining allowance is zero or negative, increasing only the other sample cannot attain the target.
Worked Example: Required Exposure Sample Size
Consider a hypothetical two-sample study targeting \(\theta=0.15\), with \(f=0.25\), \(\beta_{GX}=0.04\), \(N_Y=1{,}000{,}000\), and standardized residual variances equal to 1. The desired power is 80% for a two-sided test at \(\alpha=0.05\). The normal quantiles are \(z_{0.975}=1.960\) and \(z_{0.80}=0.8416\), so \(K=2.8016\) and \(K^2=7.8490\). Also \(V_G=2(0.25)(0.75)=0.375\), giving \(V_G\beta_{GX}^2=0.375(0.04)^2=0.0006000\).
The maximum ratio variance compatible with the approximate target is
The outcome-sample contribution to the variance is \(1/(N_Y V_G\beta_{GX}^2)=1/(1{,}000{,}000\times0.0006000)=0.0016667\). The exposure-sample contribution must therefore be no more than \(0.0028666-0.0016667=0.0011999\). Since that contribution is \(\theta^2/(N_X V_G\beta_{GX}^2)=0.0225/(0.0006000N_X)=37.5/N_X\),
Using the unrounded quantiles and intermediate values gives a threshold of approximately 31,250.4; the minimum integer sample size meeting this approximate condition is 31,251. A design can round up to at least 31,253 participants in the exposure GWAS for a small numerical safety margin. This is a normal-approximation planning result, not a guarantee of exactly 80% power in an actual analysis.
Worked Example: Allele Frequency and Design Trade-Offs
Suppose two hypothetical designs each have \(N_X=N_Y=200{,}000\), \(\beta_{GX}=0.03\), and target effect \(\theta=0.10\), with standardized residual variances of 1 and a two-sided \(\alpha=0.05\). Compare an allele frequency of \(0.50\) with an allele frequency of \(0.05\), holding the per-allele exposure effect fixed.
In both designs, the numerator of the ratio variance is \(1/200{,}000+0.10^2/200{,}000=0.00000505\), and \(\beta_{GX}^2=0.0009\). At \(f=0.50\), \(V_G=0.50\), so
The resulting power is \(\Phi(0.944-1.960)+\Phi(-0.944-1.960)\approx0.1566\), or about 16%. At \(f=0.05\), \(V_G=2(0.05)(0.95)=0.095\), and
Power is then \(\Phi(0.4115-1.960)+\Phi(-0.4115-1.960)\approx0.0696\), or about 7%. Under this hypothetical comparison, the less common allele gives less genotype variation and lower power. The comparison holds the per-allele exposure effect fixed; in real settings, effect size, imputation quality, and other design features may differ across variants, so allele frequency alone does not determine the best instrument.
Reading the Design Trade-Offs
The variance formula supports several practical conclusions. First, increasing either sample size reduces its contribution to variance, but the benefit of a very large sample in one GWAS is limited if the other GWAS remains small. Second, a larger \(|\beta_{GX}|\) reduces variance in proportion to \(\beta_{GX}^2\), while greater genotype variance \(2f(1-f)\) also improves precision when the per-allele effect is held fixed. Third, a smaller target \(|\theta|\) is harder to detect: with the design otherwise unchanged, the signal in standard-error units decreases.
When the outcome sample size is fixed, the required exposure sample can be solved as in the example. Conversely, if \(N_X\) is fixed, rearrange the target condition for \(N_Y\). In either direction, check that the fixed sample's variance contribution is below the full variance allowance. If it is not, no finite increase in the other sample alone will meet the target. This is a useful way to identify when resources should be shifted to the smaller or less informative GWAS.
These formulas address a specified effect and test threshold. If many instruments, outcomes, or hypotheses are tested, the relevant significance level may be more stringent than 0.05; using a smaller \(\alpha\) increases the critical value and generally raises the required sample size. Likewise, uncertainty in the assumed allele frequency, exposure association, residual variance, or target effect should be explored with sensitivity calculations rather than hidden behind a single power estimate.
Common Mistakes and Interpretation
- Using only the outcome sample size. The Wald ratio also uses the estimated exposure association. Include both \(1/N_Y\) and \(\theta^2/N_X\) contributions in the variance.
- Treating allele frequency as irrelevant. Under the additive dosage and Hardy–Weinberg assumptions, genotype variance is \(2f(1-f)\). A less common allele generally provides less genotype variation when its per-allele effect is held fixed.
- Assuming a large F statistic guarantees high power. Instrument strength concerns the exposure association, whereas power for the MR estimate also depends on outcome sample size, effect size, allele frequency, and the test threshold.
- Interpreting power as evidence that the instrument is valid. Power is conditional on the specified model. It does not establish that the instrument assumptions hold, nor does a statistically significant result by itself establish causation.
- Reporting a target without specifying its inputs. State the assumed causal effect, significance level, target power, allele frequency, association effect, and sample sizes. A required sample size is conditional on these design choices.
Check Your Understanding
Answer each question using the assumptions and formulas stated above.
- If the exposure sample size is fixed, what quantity must be checked before solving for the required outcome sample size?
- For allele frequency \(f=0.10\), calculate the additive genotype variance \(2f(1-f)\).
- Holding the other design quantities fixed, how does doubling \(N_Y\) change the outcome-sample contribution to the approximate variance?
- Why can a very large outcome GWAS still yield limited power if the exposure association is imprecise?
- Does a power calculation establish that the genetic instrument satisfies the assumptions needed for a causal interpretation? Explain briefly.