Tutorials › Model-Informed Drug Development (MIDD) › Time-Varying Exposure and Outcome Histories

Exposure-Response for Efficacy and Safety · Tutorial 188 of 596

Time-Varying Exposure and Outcome Histories

Build exposure histories that respect time order, and choose an analysis strategy that accounts for covariates influenced by prior exposure.

Advanced 12 min read

What You'll Learn

  • Define current, lagged, and cumulative exposure histories on a stated time scale.
  • Align exposure intervals with longitudinal outcome measurements.
  • Explain why a time-varying covariate can be both a consequence of earlier exposure and a confounder of later exposure.
  • Distinguish total effects from conditional effects when adjusting for post-exposure covariates.
  • Identify the assumptions needed for longitudinal causal comparisons.
  • Recognize when ordinary adjustment may be inadequate and when longitudinal methods are relevant.

Why Exposure and Outcome Histories Need a Time Order

In longitudinal exposure-response analysis, an exposure value is not just a number attached to a participant. Its timing matters: exposure before an outcome measurement can have a different interpretation from exposure measured afterward, and an exposure earlier in follow-up can affect both later exposure and the patient’s evolving clinical state. A useful analysis therefore begins by specifying the time scale and the order of events, not by selecting a regression formula.

For example, suppose exposure is summarized over successive weekly intervals and an outcome is measured at each week’s end. The exposure during week \(t\) can be called current exposure for the week-\(t\) outcome only if that exposure is measured before that outcome. If the outcome is measured before or during the exposure interval, the label “current” does not establish the required time order. In that case, the interval definitions must be refined or the exposure-outcome ordering described more cautiously.

Definition: Let \(A_t\) denote an exposure summary for interval \(t\), and let \(Y_t\) denote an outcome measured at a stated time in relation to that interval. The exposure history through interval \(t\) is \(\bar{A}_t=(A_0,A_1,\ldots,A_t)\). Current exposure refers to the exposure assigned to the interval preceding the outcome under study; lagged exposure refers to an earlier, specifically indexed exposure, such as \(A_{t-1}\). A cumulative or averaged history is a defined summary of multiple past exposure values, not a substitute for stating which intervals it includes.

The notation is only useful when the data structure makes its meaning explicit. Record the start and end of each exposure interval, the time of each outcome measurement, and whether the exposure summary is a concentration, an interval average, an area-under-the-curve summary, or another prespecified metric. A cumulative exposure through time \(t\), for instance, might be a sum of interval exposures, while a mean exposure might divide that sum by the number of included intervals. These summaries answer different questions and may have different units.

Constructing Histories Without Losing the Timeline

A practical data set for longitudinal analysis usually has one row per participant per outcome interval. It should preserve the exposure history available before the outcome, along with relevant covariate history. If the intended comparison concerns a one-interval lag, the row for outcome \(Y_t\) should contain \(A_{t-1}\); it should not accidentally attach \(A_t\) from a later interval. For a cumulative summary, specify its window—for example, the mean of exposures in the two intervals immediately before the outcome.

A history can retain separate exposure values or summarize them. Retaining separate values allows an analysis to distinguish current and earlier exposure, but may require more data and a prespecified model. A summary is more compact, but different histories can produce the same summary and therefore be treated as equivalent by the analysis. Neither choice is automatically superior: the history should reflect the scientific question and the temporal information the study can support.

Worked Example: Aligning Current and Lagged Exposure

In a hypothetical study, exposure is recorded as an interval-average concentration in mg/L. The outcome is a symptom score measured at the end of each interval. One participant has the following records:

IntervalExposure (mg/L)End-of-interval symptom score
148
267
385

For the interval-3 outcome, current exposure is \(A_3=8\) mg/L, provided the interval-3 exposure summary precedes the end-of-interval-3 measurement. The one-interval lag is \(A_2=6\) mg/L. A two-interval mean ending at interval 3 is \((A_2+A_3)/2=(6+8)/2=7\) mg/L. The same symptom score of 5 is therefore paired with three different, explicitly defined exposure quantities: 8 mg/L current exposure, 6 mg/L one-interval lagged exposure, and 7 mg/L mean exposure over intervals 2–3.

These quantities should not be interchanged in interpretation. A relationship with the interval-3 exposure does not establish a relationship with prior exposure, and the two-interval mean does not identify which of its component intervals is associated with the outcome. Because this is one participant’s history, it illustrates construction only; it cannot establish an exposure-response relationship.

Worked Example: Calculating a Prespecified History Summary

Suppose a hypothetical protocol defines the exposure history for an outcome at the end of interval 4 as the arithmetic mean of exposure in intervals 2, 3, and 4. A participant’s interval-average exposures are 3, 5, 7, and 9 mg/L in intervals 1 through 4.

The specified history excludes interval 1 and includes the three intervals immediately preceding the outcome:

$$ \bar{A}_{2:4}=\frac{A_2+A_3+A_4}{3} =\frac{5+7+9}{3} =\frac{21}{3} =7\ \text{mg/L}. $$

The current exposure for the end-of-interval-4 outcome is 9 mg/L, while the three-interval mean is 7 mg/L. The mean has units of mg/L because it averages concentrations. If the scientific question instead concerned total exposure over three equal-duration intervals, a sum would be 21 mg/L-intervals; for unequal interval durations, an unweighted sum would not represent a duration-weighted exposure total. The history definition must match the intended metric.

When Earlier Exposure Changes Later Covariates

A central complication arises when a covariate measured during follow-up is influenced by prior exposure and also predicts later exposure and the outcome. For example, earlier treatment exposure may change disease severity; severity may then affect subsequent dose or adherence and also predict a later outcome. The time-varying severity measure is both a consequence of earlier exposure and a potential confounder of the later exposure-outcome relationship.

This structure differs from ordinary baseline confounding. Adjusting for a baseline confounder can help control a common cause of exposure and outcome without conditioning on a consequence of treatment. By contrast, adjusting for a post-exposure covariate can block part of the effect of earlier exposure that operates through that covariate. At the same time, failing to account for the covariate can leave later exposure confounded. Thus, a single conventional adjustment decision may not answer the desired longitudinal causal question.

Key distinction: A total effect of an exposure history includes pathways through intermediate covariates that the exposure itself changes. A conditional or direct-effect contrast holds specified intermediate covariates fixed, or otherwise excludes some pathways through them. These are different estimands. A coefficient adjusted for a post-exposure covariate should not automatically be interpreted as the total effect of the exposure history.

Worked Example: Adjustment Can Change the Target Effect

Consider a hypothetical longitudinal system in which \(A_0\) is early exposure, \(L_1\) is later disease severity, \(A_1\) is subsequent exposure, and \(Y\) is a later outcome. Assume the following illustrative structural relationships, with no interaction terms:

$$ L_1=2A_0+U_L,\qquad A_1=0.5L_1+U_A,\qquad Y=20-A_0-2L_1-3A_1+\varepsilon. $$

Here \(U_L\), \(U_A\), and \(\varepsilon\) represent other influences. The coefficients are hypothetical and are used only to show how the target contrast depends on what is held fixed. Increasing \(A_0\) by one unit increases \(L_1\) by 2 units. It also increases \(A_1\), through \(L_1\), by \(0.5\times2=1\) unit.

If later severity and subsequent exposure are allowed to respond naturally to \(A_0\), the resulting change in \(Y\) is the sum of the pathways in this system:

$$ \Delta Y=-1-(2)(2)-(3)(1)=-1-4-3=-8. $$

The total contrast is therefore \(-8\) outcome units per one-unit increase in \(A_0\), under these specified structural relationships. If a regression conditions on both \(L_1\) and \(A_1\), the \(A_0\) term in the stated outcome equation is \(-1\). That conditional coefficient excludes the pathways through \(L_1\) and \(A_1\); it is not the total contrast of \(-8\). In a real analysis, the adjusted coefficient need not equal a causal direct effect unless the relevant model and causal assumptions also hold. This example shows why “adjust for every available covariate” can silently change the question.

Longitudinal Comparisons and Their Assumptions

When the target is a causal effect of an exposure history, longitudinal methods can account for covariates that both respond to earlier exposure and predict later exposure. One option is the longitudinal g-formula: it calculates outcomes under a specified exposure regime by averaging over the covariate histories expected under that regime. Another option is inverse-probability weighting, which creates a weighted comparison intended to balance measured time-varying confounders across exposure histories. These methods address a problem that a single ordinary regression adjustment may not resolve; they do not remove the need for credible assumptions or good data.

For a simple two-exposure-time setting, let \(L_1\) be measured after \(A_0\) but before \(A_1\), and let \(Y\) follow \(A_1\). Under a regime setting exposure to \(a_0\) and then \(a_1\), the g-formula averages the conditional outcome over the distribution of \(L_1\) that would arise after \(a_0\):

$$ E[Y^{a_0,a_1}] = \sum_{l_1} E[Y\mid A_0=a_0,L_1=l_1,A_1=a_1]\, P(L_1=l_1\mid A_0=a_0). $$

For continuous \(L_1\), the sum is replaced by an integral. With more follow-up times, the calculation averages over the sequential covariate distributions under the specified exposure history. This formula is not justified by time indexing alone. Its causal interpretation requires, among other conditions, that the exposure and outcome definitions are well specified, measured confounders suffice for sequential exchangeability, the exposure histories being compared are possible for relevant covariate histories (positivity), and the models used for the conditional distributions are adequately specified.

1
Define the target contrast.
Specify the exposure histories or regimes to compare and whether the target includes pathways through covariates affected by earlier exposure.
2
Order measurements in time.
For every interval, establish when exposure, covariates, and outcomes are measured. Identify which covariates are baseline and which may be post-exposure.
3
Assess identification conditions.
Consider whether important exposure-outcome confounders are measured at each time, whether relevant exposure histories occur across covariate strata, and whether the data support the needed models.
4
Choose an analysis aligned with the target.
Use a prespecified history summary for an associational question when appropriate. For a causal regime contrast with exposure-affected confounders, consider a longitudinal g-method and state its assumptions.

Diagnostics, Alternatives, and Limitations

Several checks can reveal a history or adjustment strategy that is going wrong. Inspect whether exposure intervals actually precede the paired outcome measurements; check for accidental use of future exposure; and verify that lag and cumulative windows are coded as specified. Tabulate the number of participants contributing each history at each time. If some exposure patterns are rare or absent within important covariate histories, positivity may be weak or fail, making estimates unstable or requiring extrapolation. Large changes in results across plausible history definitions are a reason to report that dependence, not to select the most favorable result.

The main alternatives answer different questions. A current-exposure model relates an outcome to the exposure assigned to its immediately preceding interval. A lagged-exposure model relates it to one or more earlier values. A cumulative-history model reduces multiple values to a summary. These may be useful associational analyses, but none by itself handles confounding merely by choosing a lag. Conventional regression adjustment can be suitable for baseline confounding or for a clearly defined conditional estimand under appropriate assumptions. For a total effect when time-varying confounders are affected by prior exposure, a longitudinal g-method may be more appropriate.

Longitudinal methods have limitations. They rely on measured confounders, adequate overlap in exposure histories, and correctly implemented or sufficiently robust estimation. Sparse data can make long histories difficult to estimate, while a compact summary may conceal meaningful differences in timing. Observational exposure histories can also reflect clinical decisions, adherence, and changing health status. Consequently, a well-constructed history improves the analysis but does not, on its own, establish causation.

  • Common mistake: “Disease severity predicts outcome, so I will adjust for its latest value in every exposure-response regression.”
  • Correction: First determine whether that severity value was measured before the exposure being analyzed and whether earlier exposure could have changed it. If it is affected by prior exposure and confounds later exposure, ordinary adjustment may block part of the earlier exposure effect while addressing later confounding. Define the estimand and consider a longitudinal method rather than treating all covariates as baseline covariates.

Check Your Understanding

Use the stated timing and estimand in each question. Solutions follow the questions.

  1. Exposure in interval 5 is measured before the interval-5 endpoint outcome. What are the current exposure and one-interval lagged exposure for that outcome?
  2. A three-interval mean uses exposures of 2, 5, and 8 mg/L. Calculate the mean and state its units.
  3. Explain why adjusting for a severity covariate affected by earlier exposure can change an estimate of the total effect.
  4. Name two assumptions needed for a causal interpretation of a longitudinal exposure-regime comparison.
  5. Why does using a lagged exposure value not, by itself, eliminate confounding?

Solutions. (1) Current exposure is \(A_5\); the one-interval lag is \(A_4\), assuming both are defined before the endpoint outcome as stated. (2) The mean is \((2+5+8)/3=15/3=5\) mg/L. (3) The covariate may lie on a pathway from earlier exposure to outcome, so conditioning on it can remove part of the total effect; it may also confound later exposure. (4) Examples include sequential exchangeability given measured covariate history and positivity for the compared exposure histories; well-defined exposure and outcome measurements and adequate model specification are also needed. (5) Earlier exposure can still be confounded by prior health status or other common causes, and the lagged value can also be related to covariates that predict the outcome.