Tutorials › Marginal Structural Models › Linear SNMMs With Two Treatment Decisions

Structural Nested Models and g-Estimation · Tutorial 330 of 501

Linear SNMMs With Two Treatment Decisions

Learn how to blip down the later treatment before estimating the earlier treatment effect, and how to diagnose when the resulting two-stage g-estimation fails.

Advanced 12 min read

What You'll Learn

  • Define distinct linear blip functions for the first and second treatment decisions.
  • State the assumptions that justify each sequential g-estimation moment condition.
  • Derive the population linear systems for estimating both blip-parameter vectors.
  • Work through a numerical example with an intermediate covariate modifying the later treatment effect.
  • Recognize how omitting the later blip can distort the estimated earlier effect.
  • Compare sequential g-estimation with the parametric g-formula and inverse-probability weighting.

Why Two Treatment Decisions Require Two Blips

With two treatment decisions, the later decision may depend on information created or observed after the first decision. That intermediate information can both predict the outcome and modify the effect of the later treatment. A single treatment-effect coefficient cannot generally represent both decisions. Instead, a structural nested mean model (SNMM) assigns a separate blip function to each decision and removes the later treatment effect before estimating the earlier one.

Let \(W\) denote baseline covariates, \(A_1\) the first binary treatment, \(L\) an intermediate covariate measured after \(A_1\), \(A_2\) the second binary treatment, and \(Y\) the final outcome. The histories immediately before treatment are \(H_1=W\) and \(H_2=(W,A_1,L)\). Write \(Y(a_1,a_2)\) for the outcome under treatment sequence \((a_1,a_2)\), and \(L(a_1)\) for the intermediate covariate under first treatment \(a_1\).

Definition: For binary treatments, a linear two-decision SNMM specifies $$ \gamma_1(a_1,W;\psi_1)=a_1 X_1(W)^\mathsf{T}\psi_1,\qquad \gamma_2(a_2,H_2;\psi_2)=a_2 X_2(H_2)^\mathsf{T}\psi_2. $$ Here \(X_1(W)\) and \(X_2(H_2)\) are specified vectors of covariates, including an intercept if desired, and \(\psi_1,\psi_2\) are parameter vectors. The first blip describes the first treatment effect on the chosen structural mean scale; the second describes the effect of the later treatment, potentially modified by the history \(H_2\).

The history in the second blip includes \(L\) because that covariate is available when \(A_2\) is chosen. It does not follow that \(L\) belongs in the first blip or in the first treatment history: \(L\) occurs after \(A_1\). The recursive blip-down outcomes are

$$ U_2(\psi_2)=Y-\gamma_2(A_2,H_2;\psi_2),\qquad U_1(\psi_1,\psi_2)=U_2(\psi_2)-\gamma_1(A_1,W;\psi_1). $$

At the true parameters, \(U_2\) removes the later treatment effect, while \(U_1\) removes both treatment effects. This ordering is essential: the first-decision equation uses the outcome after the second blip has been removed.

Assumptions and Sequential Moment Conditions

The following conditions give the population justification. Assume consistency: a person's observed \(L\) and \(Y\) equal the corresponding potential values under the treatments actually received. Assume no interference between individuals. Sequential exchangeability requires that, conditional on \(W\), \(A_1\) is independent of the relevant potential intermediate covariates and outcomes, and that, conditional on \(H_2\), \(A_2\) is independent of the potential outcomes under the alternative second treatments. Sequential positivity requires \(0<P(A_1=1\mid W)<1\) and \(0<P(A_2=1\mid H_2)<1\) on the histories being analyzed.

Assume also that the two stated blip functions correctly represent the relevant conditional mean treatment contrasts, and that the variables used in the moment equations have finite expectations. Define the true treatment probabilities \(p_1(W)=P(A_1=1\mid W)\) and \(p_2(H_2)=P(A_2=1\mid H_2)\).

Theorem: Under consistency, sequential exchangeability and positivity, if the two blip functions are correctly specified, then at the true parameter values \((\psi_1^*,\psi_2^*)\), $$ E\!\left[(A_2-p_2(H_2))X_2(H_2)U_2(\psi_2^*)\right]=0, $$ and $$ E\!\left[(A_1-p_1(W))X_1(W)U_1(\psi_1^*,\psi_2^*)\right]=0. $$

Proof. The second blip's conditional mean interpretation, together with consistency and exchangeability at the second decision, implies that after subtracting the true second blip, the conditional mean of \(U_2(\psi_2^*)\) does not depend on \(A_2\) given \(H_2\). Denote this conditional mean by \(m_2(H_2)\). Conditional on \(H_2\), \(X_2(H_2)\) and \(m_2(H_2)\) are fixed, and

$$ E[(A_2-p_2(H_2))X_2(H_2)U_2\mid H_2] =X_2(H_2)\{p_2(H_2)-p_2(H_2)\}m_2(H_2)=0. $$

Taking expectations proves the second-decision equation. For the first equation, first condition on the observed history and average over \(A_2\). By the just-established blip-down property, \(U_2\) has the conditional mean of the outcome under no second treatment. Averaging that quantity over \(L\) under the observed first treatment gives the corresponding mean under \(A_1\). The first blip model and exchangeability at the first decision then imply that, after subtracting \(\gamma_1(A_1,W;\psi_1^*)\), the conditional mean of \(U_1\) given \(W,A_1\) is the same for both values of \(A_1\). Call it \(m_1(W)\). Therefore

$$ E[(A_1-p_1(W))X_1(W)U_1\mid W] =X_1(W)\{p_1(W)-p_1(W)\}m_1(W)=0. $$

Taking expectations proves the first-decision equation. \(\square\)

Linear Equations and Sequential Estimation

The moment conditions become linear systems in the blip parameters. This makes the order of estimation explicit. For the second decision, write \(X_2=X_2(H_2)\) and \(p_2=p_2(H_2)\). Substituting \(U_2=Y-A_2X_2^\mathsf{T}\psi_2\) into its moment gives

$$ B_2\psi_2=b_2,\qquad B_2=E[p_2(1-p_2)X_2X_2^\mathsf{T}],\qquad b_2=E[(A_2-p_2)X_2Y]. $$

This follows because \(E[(A_2-p_2)A_2\mid H_2]=p_2(1-p_2)\). Once \(\psi_2\) is obtained, set \(U_2=Y-A_2X_2^\mathsf{T}\hat\psi_2\). For the first decision, the corresponding equation is

$$ B_1\psi_1=b_1,\qquad B_1=E[p_1(1-p_1)X_1X_1^\mathsf{T}],\qquad b_1=E[(A_1-p_1)X_1U_2]. $$

If each matrix \(B_j\) is positive definite, its equation has a unique solution. This requires more than positivity at each history: the covariate vectors must also have enough variation in the treatment-overlap population to identify every coefficient. In a sample, replace expectations by averages and solve the second-decision system first, then the first-decision system. The treatment probabilities in these equations must be known or validly estimated; if they are wrong, the residualized-treatment moments need not hold.

Worked Example: A Later Blip Modified by the Intermediate Covariate

Suppose \(X_1(W)=1\), \(X_2(H_2)=(1,L)^\mathsf{T}\), and both treatment probabilities equal \(0.5\). Consider the following eight observations, formed by two observations for each \((A_1,L)\) history, one at each \(A_2\):

\(A_1\)\(L\)\(A_2=0\): \(Y\)\(A_2=1\): \(Y\)
001012
011114
101315
111417

For each history, the treated-minus-untreated outcome difference is \(2\) when \(L=0\) and \(3\) when \(L=1\). The second-stage score vector \(b_2\) sums \((A_2-0.5)(1,L)^\mathsf{T}Y\). Each \(L=0\) pair contributes \((1,0)^\mathsf{T}\), and the two such pairs contribute \((2,0)^\mathsf{T}\). Each \(L=1\) pair contributes \((1.5,1.5)^\mathsf{T}\), and the two such pairs contribute \((3,3)^\mathsf{T}\). Thus \(b_2=(5,3)^\mathsf{T}\). Each observation contributes \(0.25X_2X_2^\mathsf{T}\) to \(B_2\), giving

$$ B_2= \begin{pmatrix}2&1\\1&1\end{pmatrix}, \qquad \begin{pmatrix}2&1\\1&1\end{pmatrix} \begin{pmatrix}\hat\psi_{20}\\\hat\psi_{21}\end{pmatrix} = \begin{pmatrix}5\\3\end{pmatrix}. $$

Solving gives \(\hat\psi_{20}=2\) and \(\hat\psi_{21}=1\): the estimated second blip is \(A_2(2+L)\). Blip down the observed second treatment. The resulting \(U_2\) values are \(10,10\) for \(A_1=0,L=0\), \(11,11\) for \(A_1=0,L=1\), \(13,13\) for \(A_1=1,L=0\), and \(14,14\) for \(A_1=1,L=1\). The first-stage score is \(b_1=\sum(A_1-0.5)U_2=-21+27=6\), and \(B_1=8(0.25)=2\). Hence \(\hat\psi_1=6/2=3\). The example shows both why the later blip needs \(L\) and why it is removed before estimating the first blip.

Interpretation, Diagnostics, and Alternatives

The two parameter vectors answer different structural questions. The second-stage coefficients describe how the later treatment effect varies with the history at that decision. The first-stage coefficients describe the first blip as specified by \(X_1(W)\), after accounting for the later treatment. Neither coefficient is automatically a marginal population effect under every treatment regime; interpretation depends on the SNMM, its conditioning structure, and the target contrast.

Useful checks include verifying that both treatment decisions have overlap across the histories used, examining whether the design matrices are close to singular, and checking that the specified covariates and interactions give plausible blip contrasts. Very large estimates or unstable estimates under small changes in the covariate specification can indicate sparse treatment overlap or weak identification. A zero empirical score is not by itself evidence that the blip model or treatment probabilities are correct: the equations can be solved even when the model is misspecified.

Sequential g-estimation targets structural blip parameters through treatment-residualized moments. The parametric g-formula instead models outcome and covariate transitions to calculate means under specified treatment regimes; inverse-probability weighting constructs a reweighted pseudo-population. These are alternative g-methods with different modeling and diagnostic demands. G-estimation avoids specifying the full outcome-transition distribution for this mean-model task, but it still relies on correct blip specification and valid treatment probabilities. It can also be unstable under poor overlap, and a linear blip may be too restrictive when effects vary nonlinearly.

Worked Example: What Goes Wrong If the Later Blip Is Omitted

Suppose the true outcome is \(Y=3A_1+2A_2\), with no other outcome component. Let \(P(A_2=1\mid A_1=1)=0.8\) and \(P(A_2=1\mid A_1=0)=0.2\), and let \(P(A_1=1)=0.5\). These probabilities could arise because the later treatment depends on an intermediate history associated with \(A_1\). The mean outcome in the \(A_1=1\) group is \(3+2(0.8)=4.6\); in the \(A_1=0\) group it is \(2(0.2)=0.4\). A first-stage contrast that ignores \(A_2\) is \(4.6-0.4=4.2\), not the true first blip of \(3\).

If the correct second blip \(2A_2\) is removed first, then \(U_2=Y-2A_2=3A_1\). Its contrast between the two \(A_1\) groups is exactly \(3-0=3\). Thus estimating the first effect directly from \(Y\) can attribute part of the later treatment effect to the earlier treatment. The sequential equations prevent this particular error when their assumptions and models hold.

Common Mistakes and Limits

  • Estimating the first blip from \(Y\) before removing the second. If the later treatment depends on the earlier history, its contribution can be associated with \(A_1\). First form \(U_2\), then estimate the first blip from \(U_2\).
  • Putting the intermediate covariate into the first treatment history automatically. \(L\) occurs after \(A_1\); conditioning on it in the first-decision equation can change the target and may introduce bias. Use the specified baseline history for the first decision.
  • Using the same covariate vector for both blips by default. The second decision has a different history and may require \(L\) or interactions with \(L\). Choose each vector to represent its own structural contrast.
  • Treating a solved sample equation as proof of validity. Misspecified blips, incorrect treatment probabilities, positivity problems, or rank deficiency can make the estimate misleading or unidentified.

The method is limited by its structural mean specification and by the data support for each treatment history. It does not recover contrasts that the model does not represent, and no estimating equation can identify treatment effects in histories where the relevant treatment is never observed. The extensions to more treatment times require the same recursive ordering, but their joint bookkeeping is a separate issue.

Check Your Understanding

Answer each question, then compare with the solutions.

  1. Why does \(X_2(H_2)\) potentially include \(L\), while the first-decision moment uses \(X_1(W)\)?
  2. With \(p_2=0.5\), \(X_2=(1,L)^\mathsf{T}\), and a treated-minus-untreated outcome contrast of \(4\) at \(L=2\), what restriction does this contrast impose on \(\psi_{20},\psi_{21}\)?
  3. What condition on \(B_2\) gives a unique second-blip parameter solution?
  4. Why can a first-stage analysis of \(Y\) without subtracting the second blip be biased for the first blip?

Solutions. (1) \(L\) is measured before \(A_2\), so it is part of the later decision history and may modify the later blip. It follows \(A_1\), so it is not part of the baseline history for the first-decision moment. (2) The model predicts a contrast \(\psi_{20}+2\psi_{21}\), so the restriction is \(\psi_{20}+2\psi_{21}=4\). This single contrast does not identify both coefficients. (3) \(B_2=E[p_2(1-p_2)X_2X_2^\mathsf{T}]\) must be positive definite. (4) The later treatment effect may be associated with \(A_1\), especially when its assignment depends on the intermediate history; leaving it in the outcome can make part of that effect appear to be the first blip.

Clinical Biostats