Tutorials › High-Dimensional Genomic Data Analysis › Diagnostics for LD Mismatch in Shrinkage Scores

Polygenic Risk Scores · Tutorial 574 of 795

Diagnostics for LD Mismatch in Shrinkage Scores

Learn to diagnose whether LD mismatch may be distorting shrinkage weights or score performance, and to distinguish that evidence from other causes of poor prediction.

Advanced 13 min read

What You'll Learn

  • Define discovery and reference-panel LD matrices on the same variants and allele coding
  • Calculate and interpret direct matrix discrepancy measures
  • Trace how LD mismatch can alter an LD-aware ridge solution
  • Use weight patterns and independent validation performance as complementary diagnostics
  • Recognize data and modeling issues that can mimic LD mismatch
  • Compare direct LD checks with indirect score-based evidence

Why Diagnose LD Mismatch?

LD-aware shrinkage methods use correlations among variants to separate marginal association signals from the joint effects those methods aim to estimate. Their LD matrix is often estimated from a reference panel rather than the discovery genotypes that produced the association statistics. If the two LD structures differ, the method can attribute shared signal to the wrong variants, change the sizes or signs of estimated weights, and ultimately change the score. Strong shrinkage can reduce sensitivity to some discrepancies, but it does not make a poor LD reference correct.

The aim of diagnosis is not to declare a reference panel “good” from one summary number. It is to assemble evidence from directly comparable LD estimates, the resulting weight patterns, and score behavior in data not used to choose or fit the score. These checks can reveal a mismatch, but they cannot by themselves prove that it caused a performance difference. Variant alignment, allele coding, sample size, imputation, and association-statistic quality can all produce misleading signals.

Definition: For a set of \(m\) variants, let \(R_{\mathrm{disc}}\) be the \(m \times m\) correlation matrix of their genotypes in the discovery sample, and let \(R_{\mathrm{ref}}\) be the corresponding matrix in the LD reference panel. An LD mismatch is a difference between these matrices for the same variants, allele coding, and genotype-processing conventions. A mismatch can concern individual correlations, the overall pattern of correlations, or the eigenstructure of the matrices.

Set Up a Valid Comparison

The entries of an LD matrix are genotype correlations: \(R_{jk}=\operatorname{Corr}(G_j,G_k)\), with diagonal entries equal to 1 when each variant has nonzero variance. Before comparing matrices, ensure that their rows and columns refer to the same variants in the same order and that genotype alleles are coded consistently. Strand, genome-build, and allele-alignment errors can make a nominal comparison meaningless. Remove or handle variants with zero or near-zero genotype variance; a correlation is undefined when a genotype has zero variance.

Use comparable genotype processing and, where feasible, comparable ancestry and sampling definitions. Differences in ancestry composition, relatedness, imputation quality, or variant filtering can change estimated LD or its sampling variability. When individual-level discovery genotypes are unavailable, direct comparison with \(R_{\mathrm{disc}}\) is not possible. Comparing candidate reference panels, or checking the stability of results across them, can provide indirect evidence, but it does not establish which panel matches discovery LD.

For a basic summary of discrepancy, one can compare the off-diagonal entries, since the diagonals are all 1 for standardized, nonconstant variants. For example, the maximum absolute off-diagonal difference identifies the largest pairwise discrepancy. A Frobenius discrepancy summarizes differences across all entries; it should be interpreted alongside its size relative to the matrices and the genomic region being assessed. Neither summary alone reveals whether a difference matters for the signal or weights.

$$ D_F=\left\|R_{\mathrm{disc}}-R_{\mathrm{ref}}\right\|_F =\sqrt{\sum_{j=1}^{m}\sum_{k=1}^{m} \left(R_{\mathrm{disc},jk}-R_{\mathrm{ref},jk}\right)^2}. $$

Matrix checks are usually most informative within genomic regions used by the shrinkage method. A genome-wide average can conceal a large discrepancy in a signal-rich region, while one unusually different pair can inflate a summary without materially changing a score. Inspect pairwise differences or regional summaries, and consider eigenvalues or conditioning when a method depends on matrix inversion or other matrix operations. The earlier material on stable LD matrix computation is relevant here: numerical instability and genuine biological LD differences are distinct problems and should not be confused.

Worked Example: Quantifying a Regional LD Difference

Suppose three variants have the following hypothetical discovery and reference-panel LD matrices, estimated on the same variants with consistent allele coding:

$$ R_{\mathrm{disc}}= \begin{pmatrix} 1&0.7&0.1\\ 0.7&1&0.4\\ 0.1&0.4&1 \end{pmatrix}, \qquad R_{\mathrm{ref}}= \begin{pmatrix} 1&0.2&0.1\\ 0.2&1&0.4\\ 0.1&0.4&1 \end{pmatrix}. $$

The pairwise differences are \(0.5\), \(0\), and \(0\). Thus the largest absolute off-diagonal difference is \(0.5\), for variants 1 and 2. Because the matrices are symmetric, that difference appears twice in the full matrix. Therefore

$$ D_F=\sqrt{(0.5)^2+(-0.5)^2}=\sqrt{0.5}\approx 0.7071. $$

The discrepancy is concentrated in one pair, not spread uniformly across all three pairs. Both displayed matrices are valid correlation matrices: their determinants are \(0.396\) and \(0.806\), respectively, and their principal two-by-two minors are positive. This check matters because an arbitrary table of proposed correlations need not define a valid LD matrix. The example identifies a substantial pairwise difference, but whether it alters an estimated score depends on the association signals, shrinkage procedure, and other variants in the region.

How LD Differences Can Change Shrinkage Weights

A simple quadratic approximation makes the mechanism explicit. Let \(q\) denote a vector of marginal association estimates on a common effect scale, and let \(b\) be a vector of joint variant effects. With standardized genotypes, a quadratic loss using an LD matrix \(R\) can be written as \(\tfrac12 b^\mathsf{T}Rb-q^\mathsf{T}b+\tfrac{\lambda}{2}b^\mathsf{T}b\), where \(\lambda>0\) is a ridge penalty. Minimizing this loss gives a transparent LD-aware ridge solution. This is a useful diagnostic model, not a claim that every Bayesian or penalized PRS method uses this exact objective.

$$ \widehat b(R)=(R+\lambda I)^{-1}q. $$

If the discovery matrix is the target, replacing it with a reference matrix changes the solution to \(\widehat b(R_{\mathrm{ref}})\). In general, correlated variants share marginal signal, and the matrix is part of how the procedure allocates that signal among them. A reference-panel correlation that is too small or too large can therefore produce different joint weights, even when the marginal association vector \(q\) is unchanged.

Justification: Write \(A_{\mathrm{ref}}=R_{\mathrm{ref}}+\lambda I\) and \(A_{\mathrm{disc}}=R_{\mathrm{disc}}+\lambda I\). Subtracting the two solutions and using the inverse-matrix identity gives
$$ \begin{aligned} \widehat b(R_{\mathrm{ref}})-\widehat b(R_{\mathrm{disc}}) &=(A_{\mathrm{ref}}^{-1}-A_{\mathrm{disc}}^{-1})q\\ &=A_{\mathrm{ref}}^{-1} (R_{\mathrm{disc}}-R_{\mathrm{ref}}) A_{\mathrm{disc}}^{-1}q. \end{aligned} $$

Both LD matrices are positive semidefinite. If \(\lambda>0\), the smallest eigenvalue of each matrix after adding \(\lambda I\) is at least \(\lambda\), so each inverse has operator norm at most \(1/\lambda\). It follows that

$$ \left\|\widehat b(R_{\mathrm{ref}})-\widehat b(R_{\mathrm{disc}})\right\|_2 \leq \frac{\left\|R_{\mathrm{disc}}-R_{\mathrm{ref}}\right\|_2}{\lambda^2} \left\|q\right\|_2. $$

This bound shows why a matrix discrepancy can matter more when shrinkage is weak or signals are large. It is not a universal bound for other shrinkage methods: mixture priors, continuous shrinkage, and Bayesian procedures can respond nonlinearly to LD changes. For those methods, compare their fitted weights under plausible reference panels rather than assuming this ridge formula applies.

Worked Example: A Two-Variant Ridge Weight Comparison

Consider a hypothetical two-variant region with marginal association vector \(q=(4,3)^\mathsf{T}\) and ridge penalty \(\lambda=0.5\). Suppose discovery LD is \(0.8\), whereas reference-panel LD is \(0.2\). Assume both matrices use the same variant order and standardized genotype convention:

$$ R(\rho)= \begin{pmatrix}1&\rho\\\rho&1\end{pmatrix}. $$

Using the reference matrix, \(R_{\mathrm{ref}}+0.5I\) has diagonal entries \(1.5\) and off-diagonal entries \(0.2\). Its determinant is \(1.5^2-0.2^2=2.21\), so

$$ \widehat b(R_{\mathrm{ref}}) =\frac{1}{2.21} \begin{pmatrix}1.5&-0.2\\-0.2&1.5\end{pmatrix} \begin{pmatrix}4\\3\end{pmatrix} =\frac{1}{2.21} \begin{pmatrix}5.4\\3.7\end{pmatrix} \approx \begin{pmatrix}2.443\\1.674\end{pmatrix}. $$

Using discovery LD, the off-diagonal entries are \(0.8\) and the determinant is \(1.5^2-0.8^2=1.61\):

$$ \widehat b(R_{\mathrm{disc}}) =\frac{1}{1.61} \begin{pmatrix}1.5&-0.8\\-0.8&1.5\end{pmatrix} \begin{pmatrix}4\\3\end{pmatrix} =\frac{1}{1.61} \begin{pmatrix}3.6\\1.3\end{pmatrix} \approx \begin{pmatrix}2.236\\0.8075\end{pmatrix}. $$

The second weight changes by about \(0.867\) on this effect scale, despite using the same marginal signals and penalty. This illustrates possible sensitivity; it does not establish which estimates are closer to the unknown true effects. In real analyses, uncertainty in \(q\), estimated LD, and model assumptions also matter.

Combine Matrix, Weight, and Score Diagnostics

A useful diagnostic sequence keeps direct evidence separate from downstream consequences. First, establish that the compared matrices are aligned and examine regional pairwise and matrix-level discrepancies. Next, fit the same LD-aware procedure with the same association inputs and modeling choices using each plausible LD matrix. Compare weight magnitudes, signs, and concentration in high-LD regions. Finally, assess the resulting scores in an independent validation set, using the same individuals, phenotype definition, covariates, and evaluation procedure for each score. This comparison is diagnostic, not a way to select and report a score using the same validation data.

1
Verify comparability.
Check variant identities, ordering, allele coding, genotype processing, and sample definitions before interpreting any matrix difference.
2
Locate discrepancies.
Summarize pairwise and regional differences, and check for problematic eigenstructure or numerical instability.
3
Check weight sensitivity.
Hold other inputs fixed and compare the fitted weights across defensible LD matrices; record sign changes, large magnitude changes, and changes in the distribution of weight across correlated variants.
4
Check score behavior independently.
Compare scores on the same held-out validation individuals and interpret performance differences alongside the matrix and weight evidence.

Worked Example: Interpreting Score Performance Together With LD Evidence

Suppose two hypothetical scores are fitted with the same discovery association inputs, differing only in whether they use candidate reference panel A or B. On a separate validation cohort, the correlation of score A with a continuous phenotype is \(0.12\), while the correlation for score B is \(0.20\). The corresponding squared correlations are

$$ 0.12^2=0.0144,\qquad 0.20^2=0.0400. $$

In this simple unadjusted comparison, the scores have squared correlations of \(0.0144\) and \(0.0400\), respectively. Suppose direct comparison also finds that panel A has a regional LD difference of \(0.5\) for a pair of variants with large, unstable weight changes, while panel B is closer to the discovery LD estimate in that region. Together, these observations are consistent with LD mismatch contributing to the weaker performance of score A. They do not prove causation: the validation estimates have sampling uncertainty, and other differences between the panels or fitting procedures could matter. The correlation is unitless; the squared correlation is a descriptive measure of linear association, not a causal effect or a guarantee of performance in another population.

Diagnostics, Alternatives, and Failure Modes

No single diagnostic is decisive. Direct LD comparison is the most direct check when discovery genotypes are available and comparable, but its estimates can be noisy in small samples. Weight sensitivity tests whether the fitted method reacts to plausible LD changes, but unstable weights can also reflect weak signals, collinearity, variant errors, or inadequate regularization. Validation performance measures the behavior of the score in the validation sample, but a performance difference does not identify its cause.

A useful comparison is therefore between evidence types, not a contest in which one diagnostic replaces the others:

ApproachWhat it can showMain limitation
Direct comparison of discovery and reference LDWhere genotype-correlation estimates differ on matched variantsRequires suitable genotypes; estimates may be noisy or noncomparable
Weight comparison across LD matricesWhether the fitted method is sensitive to the choice of LDSensitivity does not establish which weights are correct
Independent score evaluationWhether score behavior differs in a specified validation sampleDoes not isolate LD as the cause and is subject to sampling error
Numerical matrix checksWhether matrix conditioning or computation may be problematicNumerical stability does not establish population representativeness

If discovery genotypes are unavailable, compare multiple well-documented candidate panels and report that evidence as indirect. If a small reference panel is suspected, a larger or better-matched panel may reduce sampling error, but size alone does not ensure representativeness. If a matrix is poorly conditioned, stable computation can address numerical behavior; it cannot repair an LD matrix that represents the wrong genotype distribution. Stronger shrinkage may reduce the influence of unstable directions, but it can also suppress real signal. These are limitations to report, not reasons to interpret a convenient result as proof that the mismatch has been solved.

Common Mistake

Wrong reasoning: “The reference and discovery matrices have a large average difference, and the score performs worse, so LD mismatch caused the performance loss.” This conclusion skips the checks that the variants and alleles were matched, that the matrix discrepancy affects relevant regions, and that the performance comparison is independent and otherwise comparable.

Correction: Treat these as linked but distinct questions: are the matrices different on a valid comparison; are the fitted weights sensitive to that difference; and does the score behave differently in an independent evaluation? Consistent evidence across all three strengthens the diagnosis, but other data and model issues remain possible explanations.

Key takeaway: Diagnose LD mismatch by triangulating direct matrix comparisons, weight sensitivity, and independent score behavior. A discrepancy is evidence about the reference matrix, not by itself evidence that the score is biased or that one alternative panel is correct.

Check Your Understanding

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

  1. For matched variants, the largest absolute off-diagonal difference between \(R_{\mathrm{disc}}\) and \(R_{\mathrm{ref}}\) is \(0.35\). What does this number establish, and what does it not establish?
  2. In the ridge solution, why does a positive \(\lambda\) help make the inverse well-defined when an LD matrix is singular?
  3. A candidate panel produces more stable weights but lower validation correlation than another panel. Is that enough to conclude that it is the better LD reference?
  4. Why should a matrix discrepancy be examined regionally rather than only as one genome-wide average?

Solutions. (1) It establishes that at least one matched variant pair has correlations differing by \(0.35\) in absolute value. It does not identify the cause, establish that the difference is estimated precisely, or show that it materially changes weights or score performance. (2) An LD matrix is positive semidefinite, so its eigenvalues are nonnegative; adding \(\lambda I\) shifts each eigenvalue upward by \(\lambda>0\). The resulting matrix is positive definite and invertible. (3) No. Stability and validation performance answer different questions, and the validation result may be noisy. Check panel comparability and matrix agreement with discovery LD where available; do not infer representativeness from weight stability alone. (4) A genome-wide average can dilute a substantial difference in a signal-relevant region or be driven by a discrepancy in a region with little relevant signal. Regional inspection links matrix differences more meaningfully to weight changes.

Clinical Biostats