Tutorials › Joint Modeling of Longitudinal and Time-to-Event Data › Time Centering in Polynomial Slope Links

Association Structures · Tutorial 190 of 697

Time Centering in Polynomial Slope Links

Learn to transform polynomial trajectory coefficients under time centering and retain the same slope-linked hazard by evaluating the slope at the same actual time.

Advanced 10 min read

What You'll Learn

  • Transform intercept and slope coefficients when a quadratic trajectory is recentered.
  • Show why the fitted trajectory and its derivative are unchanged at a fixed actual time.
  • Reparameterize a slope-linked hazard without changing its value.
  • Recognize when a centered linear coefficient is not the slope at the original time origin.
  • Check random-effects covariance assumptions and diagnose inconsistent recentering.

Why Time Centering Matters for a Slope Link

A polynomial trajectory can be written using time measured from any chosen origin. Changing that origin alters the numerical values and interpretations of its coefficients, but it need not alter the trajectory itself. This distinction matters in a joint model when the hazard depends on the longitudinal marker’s slope: the hazard must use the slope at the intended actual time, not a coefficient whose meaning changed when the time origin moved.

The earlier material on slope association defines a link between the event hazard and a marker’s rate of change. Here the focus is the coordinate change for polynomial trajectories and the conditions under which it leaves that link unchanged. Time centering is a change of representation, not a change in the observed follow-up times or in the underlying marker process.

Definition: Let \(t\) denote actual follow-up time and let \(u=t-c\) be time centered at a fixed value \(c\). For a quadratic trajectory \(m_i(t)=b_{0i}+b_{1i}t+b_{2i}t^2\), its centered representation is \(m_i(t)=a_{0i}+a_{1i}u+a_{2i}u^2\). The derivative \(m_i'(t)\) is the instantaneous slope with respect to actual time. A slope-linked hazard uses that derivative, or another explicitly defined slope quantity, as a predictor.

Transforming the Quadratic Coefficients

Substitute \(t=u+c\) into the trajectory written in the original time coordinate. Expanding each term gives

$$ \begin{aligned} m_i(t) &=b_{0i}+b_{1i}(u+c)+b_{2i}(u+c)^2\\ &=(b_{0i}+c b_{1i}+c^2b_{2i}) +(b_{1i}+2c b_{2i})u+b_{2i}u^2. \end{aligned} $$

Thus the centered coefficients are \(a_{0i}=b_{0i}+c b_{1i}+c^2b_{2i}\), \(a_{1i}=b_{1i}+2c b_{2i}\), and \(a_{2i}=b_{2i}\). The intercept is now the marker level at actual time \(c\). The linear coefficient is the slope at actual time \(c\), because differentiating with respect to \(u\) gives \(a_{1i}+2a_{2i}u\), which at \(u=0\) equals \(a_{1i}\). Since \(u=t-c\), differentiation with respect to \(u\) and with respect to \(t\) gives the same rate.

The entire slope function is unchanged when evaluated at the same actual time:

$$ m_i'(t)=b_{1i}+2b_{2i}t =a_{1i}+2a_{2i}(t-c). $$

The centered linear coefficient alone is therefore not generally the slope at all times. It is the slope at the new origin \(t=c\); curvature determines how the slope changes away from that point.

Worked Example: Recenter a Quadratic Trajectory

Suppose a hypothetical subject’s marker trajectory is \(m(t)=10+1.2t+0.1t^2\), where \(t\) is measured in years and the marker in units. Recenter time at \(c=2\) years, so \(u=t-2\).

The transformed coefficients are \(a_0=10+2(1.2)+2^2(0.1)=12.8\), \(a_1=1.2+2(2)(0.1)=1.6\), and \(a_2=0.1\). Therefore the centered trajectory is \(m(t)=12.8+1.6u+0.1u^2\).

At actual time \(t=3\), \(u=1\). The original representation gives \(m(3)=10+1.2(3)+0.1(3^2)=14.5\) marker units. The centered representation gives \(m(3)=12.8+1.6(1)+0.1(1^2)=14.5\) marker units.

The original slope at \(t=3\) is \(1.2+2(0.1)(3)=1.8\) marker units per year. The centered slope at the same time is \(1.6+2(0.1)(1)=1.8\) marker units per year. The coefficients changed, but both the marker value and its slope at that actual time are preserved.

Preserving the Slope-Linked Hazard

For illustration, consider a subject-specific hazard conditional on the longitudinal trajectory and covariates \(w_i\):

$$ h_i(t\mid b_i)=h_0(t)\exp\{\gamma^\mathsf{T}w_i+\alpha_s m_i'(t)\}. $$

Here \(h_0(t)\) is the baseline hazard, \(\gamma\) is a vector of covariate coefficients, and \(\alpha_s\) is the slope-association parameter. Because \(m_i'(t)\) is measured in marker units per time unit, \(\alpha_s\) has reciprocal units; the product \(\alpha_s m_i'(t)\) is dimensionless. The link assumes that the log hazard is linear in this slope, conditional on the stated covariates and trajectory.

After centering, an equivalent expression for the same hazard is

$$ h_i(t\mid a_i)=h_0(t)\exp\{\gamma^\mathsf{T}w_i+ \alpha_s[a_{1i}+2a_{2i}(t-c)]\}. $$

No change to \(\alpha_s\) is needed: the slope predictor in brackets equals the original slope at the same actual \(t\). Nor does centering alone change \(h_0(t)\), which remains indexed by actual follow-up time. If the time coordinate for the baseline hazard is also represented using \(u\), its function must be expressed as \(h_0(u+c)\), over the corresponding time support. This relabeling is not a change in the hazard.

Worked Example: Compute the Same Hazard Ratio After Centering

Suppose the slope-linked hazard has \(\alpha_s=0.4\) per marker-unit-per-year, with other hazard predictors held equal. Compare a hypothetical subject with slope \(1.8\) marker units per year to a reference subject with slope \(1.0\) marker unit per year at \(t=3\) years. For this calculation, assume these are the slopes at that same time.

The conditional hazard ratio is \(\exp\{\alpha_s(1.8-1.0)\}=\exp\{0.4(0.8)\}=\exp(0.32)=1.377\). Thus the first subject’s hazard at that time is estimated to be about 1.38 times the reference subject’s hazard, conditional on the model and the matched values of other predictors.

Now center at \(c=2\), so \(u=1\) at \(t=3\). For the first subject, the transformed slope is \(a_1+2a_2u=1.8\) marker units per year, as calculated in the preceding example. If the reference slope is likewise evaluated at \(t=3\), it remains \(1.0\) marker unit per year. The centered calculation is therefore \(\exp\{0.4(1.8-1.0)\}=1.377\), the same hazard ratio. The numerical slope coefficient by itself is not substituted for the slope unless the evaluation time is the centered origin.

What Happens to Random Effects?

If the polynomial coefficients are random, centering transforms the random effects as well as the fixed effects. For \(b_i=(b_{0i},b_{1i},b_{2i})^\mathsf{T}\), the transformation is \(a_i=A b_i\), where

$$ A= \begin{pmatrix} 1&c&c^2\\ 0&1&2c\\ 0&0&1 \end{pmatrix}. $$

If \(b_i\) has mean vector \(\mu_b\) and covariance matrix \(D\), then \(a_i\) has mean \(A\mu_b\) and covariance matrix \(ADA^\mathsf{T}\). This follows from the rules for a linear transformation: \(E(Ab_i)=A E(b_i)\), and \(\operatorname{Cov}(Ab_i)=A\operatorname{Cov}(b_i)A^\mathsf{T}\). The same transformation applies to fixed polynomial coefficients. These changes preserve the distribution of the represented trajectories when the transformed mean and covariance are allowed.

A caveat arises when the random-effects covariance is restricted. A diagonal covariance for \(b_i\), for example, will generally not remain diagonal for \(a_i\). Fitting a diagonal covariance after centering is therefore not always the same model as fitting a diagonal covariance before centering. Exact equivalence requires transforming the covariance structure too, or using a sufficiently flexible covariance model. A different fitted result under restrictive covariance assumptions need not indicate that centering changed the data; it may indicate that the fitted models impose different restrictions.

Worked Example: Recenter a Random-Effects Covariance

Consider random intercept and slope effects \(b_i=(b_{0i},b_{1i})^\mathsf{T}\) for a linear trajectory, centered at \(c=3\) years. Then \(a_{0i}=b_{0i}+3b_{1i}\) and \(a_{1i}=b_{1i}\). Suppose the hypothetical covariance matrix is \(D=\begin{pmatrix}4&0\\0&1\end{pmatrix}\), in the corresponding squared units, with zero covariance between the original intercept and slope.

The transformation matrix is \(A=\begin{pmatrix}1&3\\0&1\end{pmatrix}\). Hence

$$ ADA^\mathsf{T} = \begin{pmatrix}1&3\\0&1\end{pmatrix} \begin{pmatrix}4&0\\0&1\end{pmatrix} \begin{pmatrix}1&0\\3&1\end{pmatrix} = \begin{pmatrix}13&3\\3&1\end{pmatrix}. $$

The centered intercept and slope now have covariance \(3\), rather than zero. The variance \(13\) for the centered intercept includes both original variation in intercepts and variation in slopes over the three-year shift. Keeping the centered covariance diagonal would discard this induced covariance and would not reproduce the same random-effects distribution.

Assumptions, Diagnostics, and Alternatives

The algebraic invariance holds when the same polynomial trajectory is represented exactly in both coordinates and its derivative is evaluated at the same actual time. For a hazard comparison, the association structure and all other predictors must also be held consistent. In applied work, the model additionally relies on the chosen trajectory being an adequate representation over the follow-up range and on the stated conditional hazard model being appropriate. Centering does not establish either assumption.

Useful checks include the following:

  • For selected actual times, calculate the trajectory and derivative from both coefficient systems. They should agree up to numerical rounding.
  • Confirm that the software’s recorded time variable, centered time variable, and hazard time are aligned, including their origins and follow-up ranges.
  • Check that fixed effects and the random-effects covariance are transformed consistently. Review warnings or estimates that change sharply under centering, especially when covariance restrictions are imposed.
  • Inspect whether the polynomial gives plausible fitted values and slopes over observed times. Agreement between two parameterizations does not diagnose a poor trajectory model.

A useful alternative is to describe a polynomial through quantities at a scientifically meaningful time: for a quadratic trajectory, the level and slope at \(c\), together with curvature. This is mathematically the centered parameterization and can make coefficients easier to communicate. Keeping the original time origin is also valid if the coefficients are interpreted at that origin and the slope is evaluated correctly. In contrast, substituting a centered coefficient into a hazard link without adjusting its evaluation time changes the predictor. Centering also differs from changing time units; a unit conversion requires additional transformations and is a separate issue.

Common Mistake and Key Limitation

A common mistake is to say, “After centering at two years, the linear coefficient is the slope at every time.” The correction is that it is the slope at two years only. With quadratic curvature, the slope at actual time \(t\) is \(a_{1i}+2a_{2i}(t-c)\). Using \(a_{1i}\) at another time changes the slope predictor and can change the modeled hazard. The effect is zero only in special cases, such as zero curvature or evaluation precisely at \(t=c\).

The key limitation is that exact algebraic equivalence does not guarantee identical numerical estimates from every fitting procedure. Constraints on random effects, penalties, priors, numerical approximation, or different handling of the baseline hazard can make the fitted analyses differ. Such differences should be investigated rather than attributed automatically to the change of time origin.

Key takeaway: Under \(u=t-c\), transform every polynomial coefficient and random-effects covariance consistently. Preserve the slope-linked hazard by evaluating the transformed derivative at the same actual time; the centered linear coefficient alone is only the slope at the new origin.

Check Your Understanding

For each question, identify which quantity is preserved and which coefficient interpretation changes.

  1. A quadratic trajectory is \(m(t)=5+0.8t+0.2t^2\). Recenter at \(c=1\). Find the centered coefficients and the slope at \(t=2\).
  2. Why does replacing \(m_i'(t)\) by \(a_{1i}\) in a slope-linked hazard generally fail when the trajectory is quadratic?
  3. If the original random intercept and slope are independent, must their centered versions also be independent? Explain.
  4. At the same actual time, two subjects have slopes differing by \(0.5\) marker units per month, and \(\alpha_s=0.3\) per marker-unit-per-month. Compute their conditional hazard ratio, taking the first subject to have the larger slope.

Solutions. 1. \(a_0=5+0.8+0.2=6.0\), \(a_1=0.8+2(1)(0.2)=1.2\), and \(a_2=0.2\). At \(t=2\), \(u=1\), so the slope is \(1.2+2(0.2)(1)=1.6\) marker units per time unit; the original derivative \(0.8+2(0.2)(2)\) also equals \(1.6\). 2. \(a_{1i}\) is the slope at \(t=c\); at another time the slope includes \(2a_{2i}(t-c)\). Omitting that term changes the hazard predictor unless it is zero. 3. No. The transformed intercept includes the original slope, inducing covariance in general; the covariance must be transformed as \(ADA^\mathsf{T}\). 4. The ratio is \(\exp\{0.3(0.5)\}=\exp(0.15)=1.162\). Conditional on the model and equal other predictors, the first subject’s hazard is about 1.16 times the second subject’s hazard at that time.

Clinical Biostats