Why Diagnose Positivity for a Candidate Regime?
A longitudinal regime specifies which treatment to give at each visit, either as a fixed sequence or as a rule that responds to the patient’s observed history. The g-formula can use fitted outcome models to estimate what would happen under such a regime, but an estimate is difficult to support when the observed data rarely include the treatment choices the regime requires. A fitted model may still return a number; that alone does not show that the data contain adequate support for it.
A positivity diagnosis therefore starts with the candidate regime and asks, at each visit, whether the treatment it assigns was observed with adequate probability among people with the relevant histories. This is a diagnostic of treatment support, not a test of whether the regime is beneficial. It can identify exact violations, where an assigned treatment is never observed in a relevant history, and practical concerns, where it is observed only rarely.
For a sustained regime, \(g_t(H_t)\) is a fixed treatment value at each visit—for example, treatment at every visit. For a dynamic regime, the assigned value can vary with history—for example, treat when a measured symptom is high and do not treat when it is low. The diagnostic is the same in both cases: check the probability of the treatment the regime actually assigns, not merely whether both treatment options occur somewhere in the data.
The relevant histories are not necessarily every history that appears in the observed data. A regime may lead to some histories more often, less often, or not at all. The positivity condition concerns histories that can occur under the regime for the target population. In practice, analysts use observed histories to assess whether there is support for those regime-relevant histories and treatment choices. This assessment is empirical and can be uncertain, especially when histories are rare or described by many variables.
History-Specific and Cumulative Support
At each visit, inspect the conditional probability of the assigned action. For binary treatment, a regime assigning \(A_t=1\) needs support from \(P(A_t=1\mid H_t=h)\); a regime assigning \(A_t=0\) needs support from \(P(A_t=0\mid H_t=h)\). A high probability for the other treatment does not support the assigned one. For example, if a dynamic rule assigns treatment only when symptoms are severe, the relevant quantity in severe-symptom histories is the probability of receiving treatment in those histories.
A useful summary is the probability of following a regime through several visits, conditional on a baseline group. For a fixed history path, the chain rule gives the product of the visit-specific treatment probabilities. If histories can vary, the path probability must also average over the histories that occur under the specified conditions. A small cumulative probability can alert us that few observed individuals may follow the complete treatment sequence. It does not replace the history-specific checks: a small product can arise from several moderately uncommon choices, while an exact violation occurs when a required conditional probability is zero.
Worked Example: A Sustained Regime Within a Baseline Group
Suppose a hypothetical cohort has baseline groups \(B\) and \(B^c\), and consider only people in group \(B\). The candidate sustained regime assigns treatment at both visits: \(A_1=1,A_2=1\). Among people in \(B\), the observed probability of treatment at visit 1 is \(P(A_1=1\mid B)=0.80\). Among those with \(A_1=1\), the visit-2 history includes a binary covariate \(L_2\): 60% have \(L_2=0\), and 40% have \(L_2=1\). The observed visit-2 treatment probabilities are 0.10 when \(L_2=0\) and 0.90 when \(L_2=1\).
The visit-2 probability of treatment, averaged over these histories among people in \(B\) who received treatment at visit 1, is
By the chain rule, the probability of following the two-visit treatment sequence within baseline group \(B\) is
Thus, 33.6% of the people in group \(B\) are expected to have followed this sequence under the stated observed probabilities. This is a conditional probability within \(B\), not an unconditional probability in the whole cohort; the prevalence of \(B\) has not been supplied. The history-specific check also shows a concern: treatment at visit 2 has probability 0.10 for \(L_2=0\), even though the averaged visit-2 probability is 0.42. The average alone would conceal that weakly supported choice.
Diagnosing Dynamic Rules Across Histories
For a dynamic regime, the action to check changes with the history. It is helpful to make a table whose rows describe histories and whose columns state the regime-assigned action, the observed conditional probability of that action, and the amount of data informing the probability. This makes it harder to mistakenly report a treatment probability averaged over histories that receive different assignments under the rule.
Worked Example: A Symptom-Based Dynamic Rule
Consider a hypothetical two-visit setting. At visit 1, the regime assigns \(A_1=1\) when baseline risk \(V\) is high and \(A_1=0\) when it is low. At visit 2, it assigns \(A_2=1\) if the measured symptom \(L_2\) is high and \(A_2=0\) if it is low. Among people with high \(V\), suppose \(P(A_1=1\mid V=\text{high})=0.70\); among those with low \(V\), suppose \(P(A_1=0\mid V=\text{low})=0.85\). At visit 2, among regime-relevant histories, suppose the estimated probability of the rule-assigned action is 0.08 for high symptoms, and the estimated probability of treatment is 0.75 for low symptoms.
At visit 1, both assigned actions have positive support in their corresponding baseline groups: 0.70 for high-risk people and 0.85 for low-risk people. At visit 2, the rule’s treatment choice for high symptoms has probability 0.08, while its no-treatment choice for low symptoms has probability \(1-0.75=0.25\) if the reported 0.75 is the probability of treatment in that low-symptom history. In this example the regime assigns no treatment for low symptoms, so the probability of the assigned choice there is 0.25.
The dynamic rule therefore has a particularly weakly supported choice among high-symptom histories: only 8% receive the assigned treatment. The low-symptom choice is also less common than its alternative, but has estimated probability 0.25. Both are positive, so these figures do not establish an exact positivity violation. They do flag that the regime relies on relatively uncommon observed actions, especially treatment for high symptoms. The check must be made within the histories where the rule assigns each action; an overall treatment proportion would not answer this question.
The same logic applies when a history includes several variables. If the regime treats patients with both high symptoms and a prior adverse event, the relevant probability is treatment conditional on that joint history—not the probability among all patients with high symptoms, nor the overall treatment proportion. As histories become more detailed, however, fewer observations may inform each conditional probability. That is why a numerical probability should be interpreted alongside the number and distribution of observations in the corresponding histories.
A Practical Assessment
A practical diagnostic can be organized around the candidate regime rather than around a single overall model summary. First state the target population and regime. Then identify, at each visit, the history variables available before treatment and the action assigned for each relevant history. Estimate or tabulate the corresponding conditional treatment probabilities and inspect how many observations support them. Where histories are continuous or high-dimensional, fitted treatment models may be used to summarize probabilities, but their predictions should be checked against the observed data and the model’s adequacy for those histories.
Record \(g_t(H_t)\) for every visit, distinguishing fixed assignments from history-dependent choices.
Specify the baseline and evolving histories at which the regime’s assigned action can occur in the target population.
For each relevant history, examine \(q_t(g_t(h)\mid h)\), not just the probability of any treatment or its average across unlike histories.
Review counts, sparse strata, and the spread of estimated probabilities; distinguish an apparent zero from an estimate based on very few observations.
Report where support is weak and, if useful, a cumulative sequence probability with its conditioning stated. Do not interpret either diagnostic as an estimated causal effect.
Worked Example: Sparse Histories and a Candidate Sequence
In a hypothetical data set, 200 people belong to baseline group \(C\). The candidate regime assigns treatment at both visits. Of the 200 people, 100 receive treatment at visit 1, so \(P(A_1=1\mid C)=100/200=0.50\). Among those 100, 80 have a common visit-2 history and 20 have a rare history. In the common history, 16 of 80 receive treatment at visit 2; in the rare history, 1 of 20 does.
The estimated visit-2 treatment probabilities are \(16/80=0.20\) in the common history and \(1/20=0.05\) in the rare history. The probability of treatment at visit 2 averaged over the histories among those treated at visit 1 is
The corresponding observed probability of following the full sequence within group \(C\) is
Equivalently, 17 of the 200 people in group \(C\) followed the sequence, and \(17/200=0.085\). The estimate for the rare history is based on only 20 people and one treated person, so 0.05 is a warning about both weak support and sampling instability; it is not precise evidence that the underlying probability is exactly 0.05. The counts also show why the cumulative figure is not enough: it summarizes the whole sequence but does not reveal that the rare-history choice is especially poorly supported.
Justification: Why the Sequence Probability Is a Product
For a two-visit sequence within baseline group \(B\), the probability of receiving both assigned treatments can be factored by the probability chain rule. If visit-2 histories \(L_2\) vary, conditioning first on \(A_1=1\) and then averaging over \(L_2\) gives
The equality follows from the chain rule in the first line and the law of total probability over the possible values \(l\) in the second. For multiple visits, the chain rule similarly factors the probability of a particular treatment path into conditional visit-specific probabilities, with histories conditioned on as they arise. This is a probability statement about observed treatment sequences. It is not a g-formula for an outcome, and it is not itself a causal contrast.
Common Mistake and Interpretation
A common mistake is to multiply probabilities reported within a baseline subgroup and label the result as an unconditional path probability. For example, if every input is conditional on \(B\), then the result is \(P(A_1=1,A_2=1\mid B)\), not \(P(A_1=1,A_2=1)\). The latter also depends on how common \(B\) is and on the path probability outside \(B\). Always carry the conditioning group through the calculation unless the inputs genuinely refer to the whole target population.
Another mistake is to treat a small positive estimated probability as proof of a formal positivity violation. A probability of 0.05 is not zero, although it may indicate practical weakness, particularly with few observations. Conversely, a model prediction bounded away from zero does not by itself guarantee adequate empirical support: the prediction may rely on model assumptions in sparse histories. Positivity diagnosis should therefore combine conditional probabilities with information about the observed histories that support them.
Check Your Understanding
Use the regime-specific treatment probabilities and conditioning information to answer each question.
- A sustained two-visit regime assigns treatment at both visits. What conditional probability should be checked at visit 2 among people treated at visit 1?
- A dynamic rule assigns treatment for high symptoms and no treatment for low symptoms. Why is the overall treatment proportion insufficient to assess support for this rule?
- Within group \(D\), suppose \(P(A_1=1\mid D)=0.60\) and \(P(A_2=1\mid A_1=1,D)=0.30\). What is the probability of the two-treatment sequence conditional on \(D\), and why is it not automatically an unconditional probability?
- What is the distinction between an exact positivity violation and a small but positive estimated treatment probability?
- Why should a cumulative sequence probability be reported alongside history-specific treatment probabilities?