Tutorials › Multi-Arm Multi-Stage (MAMS) Designs › Avoiding Covariance and Correlation Confusion

Shared-Control Correlation · Tutorial 106 of 499

Avoiding Covariance and Correlation Confusion

Learn to calculate and interpret the covariance, correlation, and standard error of contrasts that share a control, without confusing their roles or units.

Advanced 12 min read

What You'll Learn

  • Distinguish covariance, correlation, and standard error by definition, scale, and units.
  • Derive the covariance of two contrasts that use the same control group.
  • Convert between covariance and correlation using marginal variances.
  • Estimate shared-control contrast standard errors and correlations from group summaries.
  • Check calculations for sign, units, and consistency with the assumed design.

Why the Distinction Matters

When several treatment arms are compared with one control group, each treatment-control contrast includes the same control-group mean. The resulting contrasts are dependent. Describing that dependence requires care: covariance, correlation, and standard error are related quantities, but they do different jobs and have different units.

A covariance describes how two estimates vary together and is measured in squared outcome units. A correlation is the covariance scaled by the two marginal standard deviations, so it has no units and lies between \(-1\) and \(1\). A standard error describes the uncertainty of one estimate and is in the same units as that estimate. Confusing these quantities can lead to incorrect calculations even when the shared-control structure has been identified correctly.

Definition: Let \(\hat{\Delta}_j=\bar{Y}_j-\bar{Y}_0\) be the estimated difference between treatment arm \(j\) and a shared control arm \(0\). The variance of \(\hat{\Delta}_j\) measures its marginal variability, and its standard deviation is the theoretical standard error. An estimated standard error, written \(SE(\hat{\Delta}_j)\), estimates that standard deviation. For two contrasts, their covariance is \(\operatorname{Cov}(\hat{\Delta}_j,\hat{\Delta}_k)\); their correlation is that covariance divided by the product of their marginal standard deviations.

Assumptions and the Shared-Control Formula

For the basic formulas, assume each group consists of independent observations, or at least observations that are uncorrelated within that group, with a common variance within the group. Assume also that the treatment groups and control group are mutually independent. Write the variance in group \(g\) as \(\sigma_g^2\) and its sample size as \(n_g\). Under these conditions, \(\operatorname{Var}(\bar{Y}_g)=\sigma_g^2/n_g\). Independence or lack of correlation within each group matters: a common marginal variance alone does not imply that the sample mean has variance \(\sigma_g^2/n_g\).

The contrasts here are oriented in the same direction: treatment minus control. Their means are \(\Delta_j=\mu_j-\mu_0\), and their estimates are \(\hat{\Delta}_j=\bar{Y}_j-\bar{Y}_0\). The derivation below makes clear why their covariance comes from the shared control.

$$ \begin{aligned} \operatorname{Cov}(\hat{\Delta}_j,\hat{\Delta}_k) &=\operatorname{Cov}(\bar{Y}_j-\bar{Y}_0,\bar{Y}_k-\bar{Y}_0)\\ &=\operatorname{Cov}(\bar{Y}_j,\bar{Y}_k) -\operatorname{Cov}(\bar{Y}_j,\bar{Y}_0) -\operatorname{Cov}(\bar{Y}_0,\bar{Y}_k) +\operatorname{Var}(\bar{Y}_0)\\ &=0-0-0+\frac{\sigma_0^2}{n_0} =\frac{\sigma_0^2}{n_0},\qquad j\ne k. \end{aligned} $$

The zero covariance terms follow from the assumed independence of distinct groups; the final term is the variance of the shared control mean. For an individual contrast, the variance is the sum of its treatment-mean variance and control-mean variance. Thus the marginal standard deviation and the correlation of two same-direction contrasts are:

$$ \begin{aligned} \operatorname{Var}(\hat{\Delta}_j) &=\frac{\sigma_j^2}{n_j}+\frac{\sigma_0^2}{n_0},\\ SD(\hat{\Delta}_j) &=\sqrt{\frac{\sigma_j^2}{n_j}+\frac{\sigma_0^2}{n_0}},\\ \operatorname{Corr}(\hat{\Delta}_j,\hat{\Delta}_k) &=\frac{\sigma_0^2/n_0} {\sqrt{\left(\sigma_j^2/n_j+\sigma_0^2/n_0\right) \left(\sigma_k^2/n_k+\sigma_0^2/n_0\right)}}. \end{aligned} $$

If the variances are known, the displayed standard deviation is the theoretical standard error. In practice, variances are usually estimated from the data, and substituting estimates gives an estimated standard error. A covariance has units of outcome squared; each standard error has outcome units; correlation is dimensionless. These are not interchangeable labels for the same number.

Worked Example: Calculating All Three Quantities

Suppose a hypothetical continuous outcome is measured in milligrams. The control group has variance \(16\) milligrams squared and \(n_0=40\) participants. Treatment arm 1 has variance \(25\) milligrams squared and \(n_1=50\), while arm 2 has variance \(36\) milligrams squared and \(n_2=60\). Assume the independence and within-group conditions stated above, and treat these variances as known for this calculation.

The shared-control contribution is \(\sigma_0^2/n_0=16/40=0.4000\) milligrams squared. Therefore, the covariance of the two treatment-minus-control contrasts is \(0.4000\) milligrams squared.

For arm 1, the contrast variance is \(25/50+16/40=0.5000+0.4000=0.9000\) milligrams squared, so its standard error is \(\sqrt{0.9000}=0.9487\) milligrams. For arm 2, the variance is \(36/60+16/40=0.6000+0.4000=1.000\) milligrams squared, so its standard error is \(1.000\) milligram.

The correlation is the covariance divided by the product of the two marginal standard deviations: \[ \operatorname{Corr}(\hat{\Delta}_1,\hat{\Delta}_2) =\frac{0.4000}{\sqrt{0.9000}\sqrt{1.000}} =0.4216. \] The covariance retains squared units, the standard errors retain milligram units, and the correlation has no units. The positive sign is expected because both contrasts subtract the same control mean.

Converting Correctly Between Covariance and Correlation

The conversion requires the marginal standard deviations of both contrasts, not just one of them. If \(V_j=\operatorname{Var}(\hat{\Delta}_j)\) and \(V_k=\operatorname{Var}(\hat{\Delta}_k)\), then \(\operatorname{Cov}(\hat{\Delta}_j,\hat{\Delta}_k)=\rho_{jk}\sqrt{V_jV_k}\), where \(\rho_{jk}\) is their correlation. Conversely, divide the covariance by \(\sqrt{V_jV_k}\) to obtain the correlation. Since \(SE_j=\sqrt{V_j}\) when the standard errors are known, the denominator can also be written \(SE_jSE_k\).

Worked Example: Recovering a Covariance From a Correlation

Suppose two hypothetical treatment-control contrasts, measured in points, have variances \(2.25\) and \(4.00\) points squared and correlation \(0.300\). Find their standard errors and covariance.

The standard errors are \(\sqrt{2.25}=1.50\) points and \(\sqrt{4.00}=2.00\) points. Multiply the correlation by the product of these standard deviations: \[ \operatorname{Cov}(\hat{\Delta}_1,\hat{\Delta}_2) =0.300(1.50)(2.00)=0.900 \] points squared. The covariance is \(0.900\) points squared, not \(0.900\) points. As a consistency check, dividing it by \(1.50\times2.00\) returns the stated correlation, \(0.300\).

Estimating From Group Summaries

When group variances are unknown, let \(s_g^2\) be the sample variance in group \(g\). Under the same sampling assumptions, estimate the contrast variance by \(s_j^2/n_j+s_0^2/n_0\), and estimate the covariance of two same-direction contrasts by \(s_0^2/n_0\). The estimated correlation is the estimated covariance divided by the product of the two estimated standard errors. This plug-in estimate is not the true correlation known without error; it is calculated from sample information and may itself be uncertain.

Worked Example: Plug-In Estimates With Unequal Group Variances

In a hypothetical study, the observed group summaries are: control \(n_0=25\), \(s_0=4\) points, and mean \(10\) points; treatment 1 \(n_1=20\), \(s_1=5\) points, and mean \(12\) points; treatment 2 \(n_2=30\), \(s_2=6\) points, and mean \(11.5\) points. Assume independent groups and uncorrelated observations within each group. The observed means give contrasts of \(12-10=2.00\) points and \(11.5-10=1.50\) points; these point estimates do not by themselves determine the covariance.

The estimated shared-control contribution is \(s_0^2/n_0=16/25=0.6400\) points squared. The estimated variance for contrast 1 is \(25/20+16/25=1.25+0.6400=1.890\) points squared, giving \(SE(\hat{\Delta}_1)=\sqrt{1.890}=1.375\) points. For contrast 2 it is \(36/30+16/25=1.20+0.6400=1.840\) points squared, giving \(SE(\hat{\Delta}_2)=\sqrt{1.840}=1.356\) points.

The estimated covariance is \(0.6400\) points squared. Hence the estimated correlation is \[ \frac{0.6400}{\sqrt{1.890}\sqrt{1.840}} =\frac{0.6400}{1.8648} =0.3432. \] The calculation uses the estimated marginal standard deviations in the denominator. Using a variance in place of a standard deviation there would produce the wrong scale.

What the Quantities Do—and Do Not—Say

QuantityWhat it describesUnitsRole in this setting
CovarianceJoint variation of two contrast estimatesOutcome units squaredFor same-direction contrasts under the stated model, it equals the shared-control mean variance
CorrelationStandardized direction and strength of linear co-variationNoneScales covariance by both contrasts' marginal standard deviations
Standard errorSampling variability of one contrast estimateOutcome unitsSummarizes uncertainty for that contrast, not its dependence with another contrast

Correlation is not the same as the correlation between individual participants' outcomes. Here it is the correlation between two contrast estimates, which arises because they contain the same estimated control mean. Nor is correlation itself a standard error: a correlation describes dependence, while a standard error measures the marginal uncertainty of a single estimate.

A useful dimensional check catches many mistakes. If outcomes are measured in points, an estimated covariance must be in points squared, and an estimated contrast standard error must be in points. The correlation must be unit-free and between \(-1\) and \(1\). Under the same-direction, independent-group assumptions, the shared-control covariance is nonnegative, so a negative result signals a sign convention or calculation that should be checked.

Common Pitfalls and Limits

  • Calling the covariance a correlation. The shared-control term \(\sigma_0^2/n_0\) is in squared outcome units. To get correlation, divide by the product of the two contrast standard deviations.
  • Using only one contrast's uncertainty. Correlation uses both marginal standard deviations: \(\sqrt{V_jV_k}\), not just \(V_j\) or \(V_k\).
  • Reporting a standard error in squared units. A variance or covariance has squared units; taking the square root gives a standard error in outcome units.
  • Assuming group independence is enough for the sample-mean variance formula. The formula \(\operatorname{Var}(\bar{Y}_g)=\sigma_g^2/n_g\) also requires within-group observations to be independent or at least uncorrelated, with common variance.
  • Ignoring contrast direction. If one contrast is control minus treatment while another is treatment minus control, the sign of the covariance changes. The positive formula here applies to two treatment-minus-control contrasts.

The formulas also depend on the sampling structure. Correlated observations within a group, dependence between groups, or a different contrast definition can change the covariance and variance formulas. In those cases, the covariance terms that were set to zero in the derivation must be reconsidered rather than silently omitted. A different analysis may be appropriate, but it must reflect the actual dependence in the data.

Key takeaway: Start with each contrast's variance to obtain its standard error. Calculate covariance in squared outcome units, then standardize it by both marginal standard deviations to obtain correlation. Keep the contrast signs, independence assumptions, and units explicit throughout.

Check Your Understanding

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

  1. Two same-direction contrasts have variances \(9\) and \(16\) units squared and covariance \(3\) units squared. What are their standard errors and correlation?
  2. If a shared-control mean has variance \(0.5\) units squared, what is the covariance of two treatment-minus-control contrasts under the stated independent-group assumptions?
  3. Why is covariance not directly comparable to a standard error, even if both describe uncertainty?
  4. What within-group condition is needed to infer \(\operatorname{Var}(\bar{Y}_g)=\sigma_g^2/n_g\) from a common group variance?
  5. Suppose one contrast is treatment 1 minus control and the other is control minus treatment 2. What sign does the shared-control contribution make to their covariance?

Solutions. (1) The standard errors are \(\sqrt{9}=3\) and \(\sqrt{16}=4\) units. The correlation is \(3/(3\times4)=0.250\). (2) The covariance is \(0.5\) units squared, because it is the variance of the shared control mean. (3) Covariance has squared outcome units, whereas a standard error has outcome units; they represent different quantities. (4) Observations within the group must be independent or at least uncorrelated, with common variance. (5) The shared-control contribution is negative: the contrasts have opposite signs on the control mean, so the covariance contribution is \(-\operatorname{Var}(\bar{Y}_0)\).

Clinical Biostats