Tutorials › Generalized Linear Models › Exponential Correlation for Unequally Spaced Visits

Working Correlation Choices · Tutorial 861 of 981

Exponential Correlation for Unequally Spaced Visits

Learn to calculate and interpret exponential correlations from elapsed time, and see why this model differs from AR(1) when visits are irregularly spaced.

Advanced 12 min read

What You'll Learn

  • Define exponential working correlation from actual visit times and a nonnegative decay parameter
  • Calculate correlations for irregularly spaced visits
  • Relate exponential correlation to discrete-time AR(1) under equal spacing
  • Interpret the decay parameter through a correlation half-life
  • Verify positive definiteness for distinct visit times when the decay parameter is positive
  • Recognize the singular boundary case and common spacing-related mistakes

Why Visit Timing Matters

Repeated measurements are often taken at visits that do not occur at perfectly regular intervals. A working correlation that depends only on the difference between visit numbers treats the gap between visits 1 and 2 as equivalent to the gap between visits 2 and 3, even if the actual elapsed times differ. The continuous-time exponential structure instead defines dependence through the elapsed time between measurements.

This distinction matters when building a working correlation matrix for generalized estimating equations. The matrix describes the assumed association among responses within a cluster, conditional on the marginal mean model. For the exponential structure, the visit times—not just their order—determine the pairwise correlations.

Definition: For a cluster with visit times \(t_1,\ldots,t_m\) measured on a common time scale, the continuous-time exponential working correlation matrix with decay parameter \(\phi\ge 0\) is the \(m\times m\) matrix \(R(\phi)\) with entries $$ R_{jk}(\phi)=\exp\{-\phi|t_j-t_k|\},\qquad j,k=1,\ldots,m. $$ The parameter \(\phi\) is measured in inverse units of time. Every diagonal entry is 1, and each off-diagonal entry depends on the absolute time separation of the corresponding visits.

The parameter controls how quickly correlation decreases per unit of elapsed time. If \(\phi>0\), a larger time gap means a smaller correlation, and the correlation approaches zero as the gap grows. If \(\phi=0\), every finite time separation gives correlation 1. Thus, \(\phi=0\) is a boundary case, not a positive rate of decay.

Calculating a Matrix from Irregular Visit Times

The calculation is pairwise: find each absolute time difference, multiply it by \(\phi\), and apply the exponential function. The order of visits does not change the formula, although arranging them in time order makes the matrix easier to read. Symmetry follows from \(|t_j-t_k|=|t_k-t_j|\).

Worked Example: Three Unequally Spaced Visits

Suppose a patient is measured at times \(t_1=0\), \(t_2=2\), and \(t_3=5\) months, with \(\phi=0.3\) per month. The three distinct pairwise time gaps are $$ |t_1-t_2|=2,\qquad |t_1-t_3|=5,\qquad |t_2-t_3|=3. $$

The corresponding correlations are $$ R_{12}=e^{-0.3(2)}=e^{-0.6}\approx0.5488,\qquad R_{13}=e^{-0.3(5)}=e^{-1.5}\approx0.2231, $$ and $$ R_{23}=e^{-0.3(3)}=e^{-0.9}\approx0.4066. $$ The diagonal entries are 1, and symmetry supplies the entries below the diagonal. Therefore, $$ R(\phi)\approx \begin{pmatrix} 1&0.5488&0.2231\\ 0.5488&1&0.4066\\ 0.2231&0.4066&1 \end{pmatrix}. $$ The second and third visits are closer in time than the first and third visits, so their correlation is larger.

The units used for time and \(\phi\) must agree. If times are recorded in days, then \(\phi\) is a rate per day; converting the times to months while leaving the numerical value of \(\phi\) unchanged generally changes the matrix. The product \(\phi|t_j-t_k|\), rather than either quantity alone, determines each correlation.

Worked Example: Equal Spacing and Discrete-Time AR(1)

Suppose visits occur at \(t_j=j\Delta\), for \(j=0,\ldots,m-1\), with common interval \(\Delta>0\). For two visits \(j\) and \(k\), $$ R_{jk}(\phi)=e^{-\phi|j-k|\Delta} =\left(e^{-\phi\Delta}\right)^{|j-k|}. $$ Define \(\rho=e^{-\phi\Delta}\). When \(\phi>0\), \(0<\rho<1\), and the entries are \(R_{jk}=\rho^{|j-k|}\), the discrete-time AR(1) correlation form.

For example, let \(\Delta=2\) months and \(\phi=0.15\) per month. Then $$ \rho=e^{-0.15(2)}=e^{-0.3}\approx0.7408. $$ At a separation of three visit intervals, the correlation is $$ \rho^3=e^{-0.9}\approx0.4066. $$ The equality uses the exact value \(\rho=e^{-0.3}\); cubing the rounded value \(0.7408\) instead gives approximately \(0.4065\). If \(\phi=0\), then \(\rho=1\), and the resulting matrix is the singular all-ones boundary case when there is more than one visit.

The equivalence in this example depends on equal spacing. For unequal spacing, no single fixed \(\rho\) per visit-index step generally reproduces all the correlations. In the first example, the gap from visit 1 to visit 2 is two months, while the gap from visit 2 to visit 3 is three months. The exponential model uses those different gaps directly.

Interpreting the Decay Parameter

For a positive decay parameter, the time required for the correlation to fall to one half can be derived by solving for a positive time separation \(h\): $$ e^{-\phi h}=\frac12 \quad\Longrightarrow\quad -\phi h=\log(1/2)=-\log 2 \quad\Longrightarrow\quad h=\frac{\log 2}{\phi}. $$ This quantity is the correlation half-life. It is finite only when \(\phi>0\). At \(\phi=0\), correlations remain 1 at every finite time separation, so there is no finite correlation half-life.

Worked Example: Using a Half-Life to Calculate Correlations

Suppose the correlation half-life is seven days. Then \(\phi=(\log 2)/7\) per day. For visits separated by 14 days, the correlation is $$ e^{-\phi(14)} =e^{-(\log 2)(14/7)} =e^{-2\log 2} =\frac{1}{4}. $$ For visits separated by 3.5 days, it is $$ e^{-\phi(3.5)} =e^{-(\log 2)(3.5/7)} =e^{-(\log 2)/2} =\frac{1}{\sqrt{2}} \approx0.7071. $$ The second gap is half the half-life and therefore has correlation greater than one half; the calculation confirms its value.

Why the Matrix Is a Valid Correlation Matrix

A proposed working correlation must at least be positive semidefinite: for every real vector \(a\), \(a^\mathsf{T}Ra\ge0\). Otherwise it cannot be a covariance matrix for standardized variables. For distinct visit times and \(\phi>0\), the exponential matrix is in fact positive definite. The following argument proves this by constructing variables with exactly the specified correlations.

Theorem: Let \(t_1<\cdots<t_m\) be distinct real visit times and let \(\phi>0\). Then the matrix with entries \(R_{jk}=e^{-\phi|t_j-t_k|}\) is positive definite.
1
Define interval factors.
For \(i=2,\ldots,m\), set \(q_i=e^{-\phi(t_i-t_{i-1})}\). Since \(t_i-t_{i-1}>0\) and \(\phi>0\), \(0<q_i<1\).
2
Construct standardized variables.
Let \(\varepsilon_1,\ldots,\varepsilon_m\) be independent random variables with mean 0 and variance 1. Set \(Z_1=\varepsilon_1\), and recursively define \(Z_i=q_iZ_{i-1}+\sqrt{1-q_i^2}\,\varepsilon_i\).
3
Check variances and covariances.
Independence of \(\varepsilon_i\) from earlier variables gives \(\operatorname{Var}(Z_i)=q_i^2\operatorname{Var}(Z_{i-1})+(1-q_i^2)=1\). For \(j<i\), \(\operatorname{Cov}(Z_i,Z_j)=q_i\operatorname{Cov}(Z_{i-1},Z_j)\), so iterating gives \(\operatorname{Cov}(Z_i,Z_j)=\prod_{r=j+1}^{i}q_r=e^{-\phi(t_i-t_j)}\).
4
Conclude strict positive definiteness.
The vector \(Z\) is a linear transformation of \((\varepsilon_1,\ldots,\varepsilon_m)^\mathsf{T}\) with a lower-triangular transformation matrix whose diagonal entries are \(1,\sqrt{1-q_2^2},\ldots,\sqrt{1-q_m^2}\), all nonzero. Its covariance matrix is therefore positive definite, and that covariance matrix is \(R\).

For completeness, if \(B\) is the lower-triangular transformation matrix in the construction, then \(R=BB^\mathsf{T}\). For every nonzero vector \(a\), \(a^\mathsf{T}Ra=\|B^\mathsf{T}a\|^2>0\), because \(B^\mathsf{T}\) is invertible. This verifies strict positive definiteness and completes the proof. \(\square\)

If \(\phi=0\), then \(R\) is the matrix of all ones. It is positive semidefinite because \(a^\mathsf{T}Ra=(\sum_j a_j)^2\ge0\), but it is singular for \(m>1\). If two visit times coincide, the corresponding rows and columns of the exponential matrix coincide, so the matrix is also singular. Thus, for a positive definite matrix from this structure, both a positive \(\phi\) and distinct visit times are required.

Common Mistakes and Practical Meaning

  • Using visit number instead of elapsed time. Treating each successive visit as one unit apart imposes equal spacing. The exponential structure uses \(e^{-\phi|t_j-t_k|}\) with the actual time differences.
  • Calling \(\phi\) a correlation at a fixed lag. It is a decay rate, with units inverse to the time scale. A correlation at a particular gap \(d\) is \(e^{-\phi d}\).
  • Using the half-life formula at the boundary. The expression \((\log 2)/\phi\) requires \(\phi>0\). When \(\phi=0\), there is no finite half-life.
  • Assuming the exponential model allows negative correlations. For \(\phi\ge0\), all its entries are nonnegative. It is not a general substitute for every possible serial-dependence pattern.
  • Changing time units without changing the rate. A rate specified per month must be converted if times are changed to days; otherwise the products in the exponent are inconsistent.

In GEE, this structure is a way to encode a plausible pattern of within-cluster dependence when measurements occur at unequal times. It does not change the marginal mean model. As with other working correlations, its usefulness depends on whether its pattern is a sensible approximation for the study design and response process; the matrix should not be confused with a claim that the correlation has been established as the true one.

Key takeaway: Exponential working correlation is determined by elapsed time: \(R_{jk}=e^{-\phi|t_j-t_k|}\). Equal spacing reduces it to the AR(1) form with \(\rho=e^{-\phi\Delta}\) when \(\phi>0\); unequal spacing requires the actual pairwise gaps.

Check Your Understanding

Use the definition and derivations above to answer the following questions.

  1. For visits at times 0, 1, and 4 days, write the exponential correlation matrix in terms of \(\phi\).
  2. If \(\phi=0.2\) per day, calculate the correlation between visits separated by five days.
  3. For equally spaced visits separated by \(\Delta\), derive the corresponding discrete-time AR(1) parameter.
  4. Why is there no finite correlation half-life when \(\phi=0\)?
  5. State the conditions under which the exponential correlation matrix is positive definite, rather than merely positive semidefinite.
Clinical Biostats