Tutorials › High-Dimensional Genomic Data Analysis › Bayesian Posterior Effects Under an Infinitesimal Prior

Polygenic Risk Scores · Tutorial 567 of 795

Bayesian Posterior Effects Under an Infinitesimal Prior

Derive posterior mean variant effects under a Gaussian infinitesimal prior, and see how prior variance and GWAS uncertainty determine the amount of shrinkage.

Advanced 12 min read

What You'll Learn

  • State the likelihood and prior assumptions behind the independent-variant Gaussian model
  • Derive the posterior mean and variance by completing the square
  • Calculate how a variant’s standard error and prior variance determine its shrinkage weight
  • Interpret the posterior effect on the genotype and phenotype scales
  • Recognize when linkage disequilibrium, selection, or scale mismatch undermines the calculation
  • Compare posterior-mean shrinkage with hard thresholding and a ridge-type estimate

Why Put a Distribution on Variant Effects?

A genome-wide association study (GWAS) estimates many variant effects, often with substantial sampling error. Using every estimate without adjustment can carry that noise into a polygenic risk score. Shrinkage reduces the magnitude of uncertain estimates by combining the GWAS evidence with a model for plausible effect sizes. Here the model is deliberately simple: variants are treated as independent, and every effect is drawn from the same zero-centered Gaussian prior. This is the infinitesimal prior.

The result is a transparent benchmark for understanding Bayesian shrinkage, not a general solution for correlated genotypes. In particular, the calculation below assumes independent effect estimates. When variants are in linkage disequilibrium (LD), information about one effect is entangled with information about others, and a one-variant-at-a-time formula need not give the appropriate posterior. That more complex setting is outside this tutorial.

Definition: Let \(\beta_j\) denote the effect of variant \(j\) on the phenotype, measured per one-unit increase in its genotype predictor. An infinitesimal Gaussian prior assumes \(\beta_j\sim N(0,\tau^2)\) independently across variants, where \(\tau^2\) is a common prior variance. The prior is called infinitesimal because it allows every variant to have a nonzero effect; it does not assign a separate probability that an effect is exactly zero.

Model and Assumptions

For a single variant \(j\), let \(\hat{\beta}_j\) be its GWAS effect estimate and \(SE_j\) its standard error. The summary-statistic likelihood is

$$ \hat{\beta}_j\mid\beta_j\sim N(\beta_j,SE_j^2), \qquad \beta_j\sim N(0,\tau^2). $$

The first distribution describes sampling uncertainty in the GWAS estimate when the true effect is \(\beta_j\); the second describes prior variation in effects before observing that estimate. The posterior is the distribution of \(\beta_j\) after combining both. For the calculations to have the stated form, assume that the GWAS estimate is unbiased and approximately normally distributed with a correctly estimated standard error, and that the prior is appropriate on the same effect scale. Also assume that effect estimates for different variants can be treated as independent. This is reasonable in an idealized setting with independent genotype columns (or a suitable conditional analysis); correlated genotype columns generally violate it.

One way to motivate the likelihood is a Gaussian linear model with centered, mutually orthogonal genotype columns and independent errors with common variance. If the phenotype is regressed jointly on these columns, orthogonality separates the estimates, and the conditional estimate for each variant has a normal sampling distribution. In practice, summary-statistic analyses may use approximations; the formula is only as reliable as the likelihood and standard errors supplied to it.

Effect units matter. If each genotype column is standardized to have mean zero and variance one, \(\beta_j\) is the phenotype change per one standard deviation of genotype. If dosage is left on its allele-count scale, the effect is per additional effect allele. The prior variance \(\tau^2\) must be specified on that same scale and in squared phenotype units.

Deriving the Posterior

The likelihood as a function of \(\beta_j\) is proportional to \(\exp\{-(\hat{\beta}_j-\beta_j)^2/(2SE_j^2)\}\), while the prior density is proportional to \(\exp\{-\beta_j^2/(2\tau^2)\}\). Multiplying them gives the posterior density up to a constant. Collecting the terms that involve \(\beta_j\) yields

$$ -\frac{1}{2}\left[ \left(\frac{1}{SE_j^2}+\frac{1}{\tau^2}\right)\beta_j^2 -2\frac{\hat{\beta}_j}{SE_j^2}\beta_j \right]. $$

Complete the square. The coefficient of \(\beta_j^2\) is the posterior precision, and the center of the square is the posterior mean:

$$ \begin{aligned} \beta_j\mid\hat{\beta}_j &\sim N\left( \frac{\hat{\beta}_j/SE_j^2}{1/SE_j^2+1/\tau^2}, \frac{1}{1/SE_j^2+1/\tau^2} \right)\\ &=N\left( \frac{\tau^2}{\tau^2+SE_j^2}\hat{\beta}_j, \frac{\tau^2 SE_j^2}{\tau^2+SE_j^2} \right). \end{aligned} $$

Thus the posterior mean is a weighted average of the GWAS estimate and the prior mean of zero. Since the prior mean is zero, the estimate is multiplied by a shrinkage weight

$$ w_j=\frac{\tau^2}{\tau^2+SE_j^2}, \qquad E(\beta_j\mid\hat{\beta}_j)=w_j\hat{\beta}_j. $$

The posterior variance is the inverse of the sum of prior and data precisions. Its square root describes posterior uncertainty about the effect under this model; it is not the standard error of the raw GWAS estimate.

Theorem: Under the stated normal likelihood and Gaussian prior, the posterior mean is the Bayes estimate under squared-error loss. For a fixed variant, its shrinkage weight is between zero and one. It depends on the relative size of the prior variance and sampling variance, not on the sign of the observed estimate.

What Controls the Shrinkage?

The estimate is shrunk more when its sampling variance is large relative to the prior variance. The weight is \(w_j=1/(1+SE_j^2/\tau^2)\), so it is close to zero when \(SE_j^2\) greatly exceeds \(\tau^2\), and close to one when \(SE_j^2\) is small compared with \(\tau^2\). With a fixed prior variance, a more precise estimate is shrunk less. With a fixed standard error, increasing \(\tau^2\) also reduces shrinkage.

The limiting cases make the role of the prior clear. As \(\tau^2\) approaches zero, the prior concentrates at zero, \(w_j\) approaches zero, and the posterior mean approaches zero. As \(\tau^2\) becomes very large, the prior becomes diffuse, \(w_j\) approaches one, and the posterior mean approaches the GWAS estimate. These are limits, not recommendations to choose an extreme prior.

For example, with standardized genotypes and a fixed-design linear model whose residual variance is \(\sigma_e^2\), the standard error is \(SE_j=\sigma_e/\sqrt{n}\) when the genotype column has sum of squares \(n\). The shrinkage weight can then be written as

$$ w_j=\frac{n\tau^2}{n\tau^2+\sigma_e^2}. $$

This expression shows how greater sample size can increase the influence of the data, provided the model and measurement scale remain appropriate. In actual GWAS applications, variant-specific standard errors can differ because genotype variation and other design features differ, so the per-variant \(SE_j\) formula is the more general one.

Worked Example: Shrinking One Estimate

Suppose a hypothetical GWAS reports \(\hat{\beta}_1=0.20\) phenotype units per one-standard-deviation increase in genotype, with \(SE_1=0.05\) in the same units. Suppose the prior standard deviation is \(\tau=0.10\), so \(\tau^2=0.0100\). The stated likelihood and prior are normal, unbiased, and on the same scale; assume this variant is independent of the others.

The shrinkage weight is

$$ w_1=\frac{0.0100}{0.0100+0.05^2} =\frac{0.0100}{0.0125}=0.800. $$

Therefore the posterior mean effect is \(0.800(0.20)=0.160\) phenotype units per genotype standard deviation. The posterior variance and standard deviation are

$$ \operatorname{Var}(\beta_1\mid\hat{\beta}_1) =\frac{0.0100(0.0025)}{0.0125}=0.00200, \qquad SD(\beta_1\mid\hat{\beta}_1)=\sqrt{0.00200}=0.04472. $$

Under this model, the posterior mean is smaller in magnitude than the observed estimate, and the posterior standard deviation is about \(0.0447\) phenotype units per genotype standard deviation. This is a conditional Bayesian summary given the chosen prior and likelihood, not evidence that the true effect must equal \(0.160\).

Worked Example: Different Precision, Different Shrinkage

Consider two hypothetical independent variants, both with \(\hat{\beta}=0.12\) phenotype units per one-standard-deviation increase in genotype. Variant A has \(SE_A=0.03\); variant B has \(SE_B=0.08\). Use the same prior standard deviation \(\tau=0.06\), or prior variance \(0.0036\), for both. Assume normal, unbiased sampling distributions with the reported standard errors and a shared, correctly scaled prior.

For variant A,

$$ w_A=\frac{0.0036}{0.0036+0.0009}=0.800, \qquad E(\beta_A\mid\hat{\beta}_A)=0.800(0.12)=0.096. $$

For variant B,

$$ w_B=\frac{0.0036}{0.0036+0.0064}=0.360, \qquad E(\beta_B\mid\hat{\beta}_B)=0.360(0.12)=0.0432. $$

The observed estimates are equal, but the less precise estimate is shrunk more. That difference follows from its larger sampling variance, not from a different observed effect direction or magnitude.

From Posterior Effects to a Score

A polygenic risk score is a weighted sum of genotype values. Under this model, posterior mean effects can be used as weights, just as estimated effects can. This does not change the definition of a score; it changes the effect weights supplied to it.

Worked Example: Applying Shrunk Effects to Genotypes

For two hypothetical independent variants, suppose the posterior mean effects are \(0.096\) and \(0.0432\) phenotype units per standardized genotype, as in the preceding calculation. A target individual has standardized genotypes \(x_1=1.0\) and \(x_2=-0.5\). The genotype scale and allele coding are aligned with the GWAS effects, and the independent-variant model is assumed to apply.

The posterior-mean score is the sum of genotype values multiplied by posterior mean effects:

$$ S=(1.0)(0.096)+(-0.5)(0.0432) =0.096-0.0216=0.0744. $$

The score is \(0.0744\) units on the model's phenotype-prediction scale, before any separate calibration or intercept adjustment. It is not automatically an individual-level outcome prediction: that interpretation also depends on the phenotype model, covariates, and score calibration.

Diagnostics, Alternatives, and Limitations

The formula is simple enough that its assumptions deserve explicit checks. First, compare effect and standard-error scales: an allele-count effect cannot be combined with a prior variance chosen for effects per standardized genotype without a conversion. Second, check that reported standard errors are plausible and correspond to the same effect estimates; a misspecified standard error directly changes the shrinkage weight. Third, inspect whether correlated variants are being treated as independent. With LD, marginal GWAS estimates can reflect neighboring variant effects, so multiplying each estimate by its own scalar weight does not generally resolve that dependence.

Selection also matters. If estimates were selected because they had unusually small p-values, their sampling distribution after selection is not simply the unselected normal likelihood stated above. Applying the formula without accounting for that selection can leave biased or overly optimistic effects. In addition, a common \(\tau^2\) assumes the same prior effect variance across all variants. If that assumption or the zero-centered prior is poorly calibrated, posterior means can be systematically over- or under-shrunk. The posterior formulas are conditional on the model; they do not establish that the model is biologically correct.

The posterior mean is closely related to ridge-type shrinkage: both reduce effect estimates continuously toward zero. Under the independent normal model, the scalar weight above is the exact posterior-mean rule. Hard thresholding instead sets selected estimates to zero and leaves others unchanged, creating a discontinuity at its cutoff. Neither a ridge-type rule nor hard thresholding is automatically superior; their behavior depends on assumptions, tuning, and the prediction goal. The calculation here is useful because it makes the role of prior variance explicit, but it does not replace LD-aware genome-wide shrinkage models.

1
Check the inputs.
Confirm that \(\hat{\beta}_j\), \(SE_j\), and \(\tau^2\) use a consistent genotype and phenotype scale.
2
Check the model.
Assess whether normal sampling error, a zero-centered common-variance prior, and independence across variants are defensible for the analysis at hand.
3
Compute and interpret.
Calculate \(w_j\), then \(w_j\hat{\beta}_j\); report the effect units and make clear that the result is conditional on the stated model.
Common pitfall: “The estimate is statistically significant, so it should receive little shrinkage.” Significance alone does not determine the posterior weight. Under this model, shrinkage is determined by \(\tau^2\) relative to \(SE_j^2\). Two estimates with the same p-value can have different standard errors and effect scales, and a p-value by itself is not enough to compute the posterior mean.
Key takeaway: Under an independent Gaussian likelihood and a zero-centered Gaussian infinitesimal prior, the posterior mean is the GWAS estimate multiplied by \(\tau^2/(\tau^2+SE_j^2)\). A larger prior variance means less shrinkage; a larger sampling variance means more. The result is only as trustworthy as the scale, likelihood, prior, and independence assumptions.

Check Your Understanding

Answer each question, then compare your reasoning with the solutions below.

  1. A hypothetical estimate is \(0.10\) phenotype units with standard error \(0.04\). If \(\tau=0.08\), calculate the posterior mean.
  2. With a fixed \(\tau^2\), what happens to the shrinkage weight as \(SE_j\) increases? Explain using the formula.
  3. Why is an allele-count effect estimate not automatically compatible with a prior variance specified for standardized-genotype effects?
  4. Why can the one-variant formula be inappropriate when genotype columns are correlated?

Solutions. (1) The prior variance is \(0.08^2=0.0064\), and the sampling variance is \(0.04^2=0.0016\). Thus \(w=0.0064/(0.0064+0.0016)=0.800\), so the posterior mean is \(0.800(0.10)=0.080\) phenotype units. (2) Since \(w=\tau^2/(\tau^2+SE_j^2)\), increasing \(SE_j\) increases the denominator while leaving the numerator fixed, so \(w\) decreases and the estimate is shrunk more. (3) The effect units differ: one estimate is per additional allele and the other per one standard deviation of genotype. The effect and prior variance must be converted to a common scale before combining them. (4) Correlated genotype columns make variant estimates statistically dependent and can cause a marginal estimate to reflect effects at other variants. The independent likelihood factorization used in the derivation then does not describe the joint evidence.

Clinical Biostats