Tutorials › Statistical Genetics › Adverse Drug Reaction Outcomes And Competing Events

Pharmacogenomic Association and Translation · Tutorial 976 of 989

Adverse Drug Reaction Outcomes And Competing Events

Learn to define a toxicity endpoint and estimate its real-world cumulative incidence when death or another event can occur first.

Advanced 10 min read

What You'll Learn

  • Specify a time origin, toxicity definition, event window, and event types
  • Distinguish competing events from censoring and treatment changes
  • Interpret cause-specific hazards and cumulative incidence in context
  • Calculate cumulative incidence with the Aalen–Johansen estimator
  • Recognize why censoring competing events in Kaplan–Meier analysis can misstate absolute toxicity risk

Why Adverse-Event Endpoints Need Careful Definition

A pharmacogenomic study may ask whether a genotype is associated with toxicity after a drug is started. A percentage with “any adverse event” can be hard to interpret unless the event definition, observation period, and treatment history are clear. Time-to-event analysis adds another complication: a patient may die, discontinue treatment, or switch drugs before the toxicity of interest is observed. These events can change the chance of observing the endpoint, and their statistical role depends on the question being asked.

The key is to define the outcome first, then determine what each intervening event means for that outcome. Death before a nonfatal toxicity usually makes that toxicity impossible to observe afterward. By contrast, discontinuation or switching may end exposure to the original drug without ending follow-up for toxicity. Neither should automatically be treated as ordinary censoring.

Definition: A time-to-toxicity endpoint specifies a time origin (often the first dose), a toxicity event or set of events, and a period during which events count. A competing event is an event that occurs first and makes the endpoint of interest impossible to occur subsequently, or changes the endpoint’s meaning under the stated definition. A cumulative incidence function (CIF) for toxicity is \(F_1(t)=P(T\le t, J=1)\): the probability that toxicity is the first event type by time \(t\).

Specify the Endpoint and the Event Structure

Let \(T\) be the time from the chosen origin to the first event of any type, and let \(J\) identify that event type. For example, \(J=1\) might denote the toxicity endpoint, \(J=2\) death before toxicity, and \(J=3\) another event defined as competing. Let \(C\) be the time of loss to follow-up or administrative study end. The observed time is \(\min(T,C)\), accompanied by an indicator of whether an event was observed and, if so, its type.

A usable endpoint description should state the toxicity criteria, severity threshold if relevant, whether the endpoint is a first event or includes recurrences, the time origin, and the end of the observation window. It should also state how events after treatment cessation or switching are handled. For instance, “first qualifying toxicity within 90 days of the first dose, followed regardless of treatment discontinuation” is a different endpoint from “first toxicity while receiving the original drug.”

The event classification follows the estimand—the quantity the analysis is intended to describe. Death is usually a competing event for a first nonfatal toxicity endpoint: after death, the patient cannot experience that endpoint. Discontinuation and switching require more thought. If follow-up continues and the endpoint includes toxicity regardless of later treatment, they do not prevent observation and should not be coded as competing events. If the endpoint is explicitly toxicity during original-drug exposure, stopping or switching may end the endpoint’s risk period. That defines a different quantity; it does not make the resulting estimate interchangeable with risk after treatment initiation.

Worked Example: Classifying Events for a Defined Endpoint

Suppose a hypothetical study defines the endpoint as the first laboratory-confirmed liver injury within 90 days after a patient’s first dose, whether or not the patient later stops or switches treatment. The study continues to collect laboratory results after treatment changes.

A patient has liver injury on day 24: this is the endpoint event. A patient dies on day 18 without prior liver injury: death is a competing event because liver injury cannot be observed after death. A patient stops the drug on day 10, switches on day 15, and has liver injury on day 24: that liver injury still counts under the stated definition. A patient is lost to follow-up on day 20 without a prior event: this is censoring, not a competing event, because the event may still have occurred later but is no longer observed.

The classification depends on the endpoint. If the definition instead counted only injury while receiving the original drug, stopping or switching would end that endpoint’s risk period. The two definitions answer different questions, so the analysis must not silently substitute one for the other.

Cause-Specific Hazards and Cumulative Incidence

For event type \(j\), the cause-specific hazard describes the instantaneous event rate among people who have not yet experienced any event. In continuous time it is written \(\lambda_j(t)\). In grouped time, if \(Y_k\) people are event-free and under observation just before event time \(t_k\), and \(d_{jk}\) experience event type \(j\) at that time, the corresponding event proportion is \(d_{jk}/Y_k\). A cause-specific hazard is conditional on remaining event-free; it is not itself the probability of toxicity by a specified time.

For absolute risk in the presence of competing events, estimate the CIF. At each event time, the probability of being free of all event types so far is multiplied by the probability of avoiding every event type at that time. The toxicity-specific contribution at an event time is that event-free probability immediately beforehand times the proportion experiencing toxicity at that time.

Estimator: Suppose event types are \(1,\ldots,K\), where type 1 is the toxicity of interest. At event time \(t_k\), \(Y_k\) is the number at risk just before that time and \(d_{jk}\) is the number with event type \(j\). The Aalen–Johansen estimator of the event-free probability just before \(t_k\), and of the toxicity CIF, is
$$ \widehat{S}(t_k-) = \prod_{l:\,t_l<t_k} \left( 1-\frac{d_{1l}+\sum_{j=2}^{K}d_{jl}}{Y_l} \right), \qquad \widehat{F}_1(t) = \sum_{k:\,t_k\le t} \widehat{S}(t_k-)\frac{d_{1k}}{Y_k}. $$

The product includes the toxicity count and every competing-event count. Censoring is not an event type in that product: censoring reduces later risk sets, while observed event types reduce the event-free probability. The estimator relies on adequately observed event types and censoring that is independent of future event experience, at least conditionally on variables accounted for in the analysis. In a genotype comparison, the CIF describes risk by genotype group; it does not alone establish that genotype caused a difference.

Why the CIF Formula Works

The formula follows by updating two probabilities at each event time. Immediately before \(t_k\), suppose the estimated probability of remaining event-free is \(\widehat{S}(t_k-)\). Among the \(Y_k\) people at risk, the observed proportion with any event at that time is \((d_{1k}+\sum_{j=2}^{K}d_{jk})/Y_k\). Thus the probability of remaining event-free after that time is updated by multiplying by one minus this proportion. The event-free probability before the next event time is therefore the product of those updates.

At \(t_k\), the fraction of the risk set experiencing toxicity is \(d_{1k}/Y_k\). Multiplying it by the probability of having reached \(t_k\) without any event gives the probability mass assigned to toxicity at that time. Summing these mutually exclusive contributions through time \(t\) gives the CIF. This also shows why the calculation must account for competing events: they reduce the probability of reaching later times event-free.

Worked Example: Calculating Toxicity Cumulative Incidence

Consider a hypothetical cohort of 100 patients. At day 10, 8 have toxicity and 4 die before toxicity. Eight additional patients are censored before day 20. Just before day 20, the risk set is therefore \(Y_2=80\); by that time, 8 have toxicity and 4 die. Estimate the toxicity CIF through day 20.

At day 10, the toxicity contribution is \(8/100=0.0800\). The probability remaining free of both toxicity and death immediately afterward is \(1-(8+4)/100=0.880\). The eight patients censored before day 20 do not count as events, but they are no longer in the day-20 risk set.

The day-20 toxicity contribution is \(0.880(8/80)=0.0880\). Adding the two contributions gives

$$ \widehat{F}_1(20) = \frac{8}{100} + \left(1-\frac{8+4}{100}\right)\frac{8}{80} = 0.0800+0.0880 = 0.168. $$

The estimated probability of toxicity being the first event by day 20 is 16.8% for this hypothetical cohort. The calculation correctly reduces the day-20 contribution for the patients who experienced either type of event on day 10.

Why Treating Competing Events as Censoring Can Mislead

A Kaplan–Meier estimate for toxicity can be computed by treating deaths as censored observations. That calculation is often interpreted as a “net” risk under a hypothetical setting in which competing events do not occur, subject to strong assumptions. It is not generally the observed probability of toxicity by time \(t\) in the population where deaths occur. Removing deaths from the risk set as if they were ordinary losses to follow-up can overstate real-world toxicity incidence, because those patients cannot subsequently experience the nonfatal toxicity.

Worked Example: Comparing the CIF With a Kaplan–Meier Calculation

Use the hypothetical counts from the previous example. The day-10 toxicity proportion is \(8/100=0.0800\). If deaths are treated as censored, the Kaplan–Meier calculation uses a day-20 toxicity proportion of \(8/80=0.100\). Its estimated net risk is

$$ 1-(1-0.0800)(1-0.100) = 1-(0.920)(0.900) = 0.172. $$

This is 17.2%, compared with the CIF of 16.8%. The Kaplan–Meier result is not the observed probability of toxicity before death; it answers a different, hypothetical net-risk question. The numerical difference happens to be small here, but it can be substantial when competing events are frequent.

Discontinuation, Switching, and Observation

Stopping or changing treatment can have several distinct roles. If outcomes continue to be collected and toxicity after a switch counts, the switch is not a competing event for that endpoint. The study may instead describe toxicity under a treatment policy that allows subsequent treatment changes. If observation stops at discontinuation, the resulting missing follow-up is censoring; treating it as ordinary independent censoring is defensible only if the censoring mechanism is independent of future toxicity, possibly conditional on measured information. That assumption can fail when early symptoms or perceived risk prompt treatment cessation.

If the endpoint is toxicity while on the original drug, discontinuation or switching can terminate the period in which the endpoint is defined. The resulting incidence is a probability of toxicity before treatment change, not an estimate of the risk that would have occurred had all patients continued therapy. If discontinuation itself is part of a composite adverse-outcome endpoint, it is an endpoint component rather than a competing event. State these choices explicitly; statistical software cannot choose the scientific estimand.

Worked Example: Comparing Genotype-Specific CIFs

In a hypothetical study, two genotype groups are followed for two event times, with death competing against toxicity and no censoring. In group A, \(n=100\): at the first time there are 10 toxicities and 5 deaths, leaving 85 event-free; at the second time there are 9 toxicities. In group B, \(n=100\): at the first time there are 16 toxicities and 4 deaths, leaving 80 event-free; at the second time there are 8 toxicities.

For group A, the estimated toxicity CIF through the second time is

$$ \widehat{F}_{1,A} = \frac{10}{100} + \left(1-\frac{10+5}{100}\right)\frac{9}{85} = 0.100+0.850(0.1059) = 0.190. $$

For group B, it is

$$ \widehat{F}_{1,B} = \frac{16}{100} + \left(1-\frac{16+4}{100}\right)\frac{8}{80} = 0.160+0.800(0.100) = 0.240. $$

The estimated risks differ by \(0.240-0.190=0.050\), or 5.0 percentage points, through the second event time. This is a descriptive contrast for the hypothetical groups. It does not, by itself, show that genotype caused the difference or quantify sampling uncertainty.

Common Mistakes and Practical Checks

  • Using “toxicity risk” without defining the endpoint. Specify the event criteria, time origin, observation window, and treatment-change rule.
  • Calling every treatment stop a competing event. A stop is competing only if it prevents the defined endpoint from occurring or changes its meaning. If follow-up continues and the endpoint still counts, it is not competing.
  • Treating death as ordinary censoring and interpreting one minus Kaplan–Meier as observed risk. Use a competing-risk CIF when the target is actual toxicity probability in the presence of death.
  • Omitting the toxicity count from the event-free survival update. The product for \(\widehat{S}\) must include the toxicity count and all competing-event counts; otherwise it does not represent being free of every event type.
  • Interpreting a genotype-specific CIF contrast as causal. The contrast is an association unless the design and analysis support a causal interpretation.
Key takeaway: Define what counts as toxicity and how treatment changes affect follow-up before analyzing time to event. For the observed probability of toxicity when death or another event can occur first, estimate a cumulative incidence function that accounts for every event type.

Check Your Understanding

Answer each question by referring to the endpoint and event process, not just the event label.

  1. For a first nonfatal toxicity endpoint, why is death before toxicity generally a competing event rather than ordinary censoring?
  2. When can discontinuation be treated as censoring, and what assumption is needed for that treatment?
  3. In the Aalen–Johansen estimator, which event counts belong in the product used to estimate event-free probability?
  4. What quantity does one minus a Kaplan–Meier estimate represent when competing deaths are censored, and why is it not generally the observed toxicity risk?
  5. A study follows patients after switching and counts toxicity regardless of their later drug. Is switching automatically a competing event? Explain.
Clinical Biostats