🤖 AI Summary
This study addresses the limited accessibility of the g-formula in causal inference due to its mathematically opaque formulation for those with modest statistical backgrounds. Under the standard assumptions of consistency, positivity, and conditional exchangeability, the authors systematically reformulate the g-formula into two nonparametrically equivalent representations: a non-iterative (NICE) and an iterative (ICE) form. This novel decomposition clarifies the g-formula’s intrinsic connections to the law of iterated expectations and conditional expectation operators. Through three progressively complex numerical examples—spanning settings with both fixed and time-varying confounders—the paper intuitively illustrates the computational mechanics and causal identification logic underlying the g-formula. The proposed framework substantially enhances interpretability and generalizability, offering practitioners a transparent and unified pathway for estimating causal effects.
📝 Abstract
The g-formula is a foundational tool for identifying causal effects in observational data. This tool is based on the law of iterated expectation, a key mathematical identity in statistics. However, the notation with which the law of iterated expectation and the g-formula is expressed can be opaque to those with little background in statistics. We provide a primer introducing the law of iterated expectation, the integration notation used to express it, and its role for causal effect identification via the g-formula. Under the assumptions of causal consistency, positivity, and conditional exchangeability, the law of iterated expectation can be rewritten as a causal standardization formula (the g-formula) in two nonparametrically equivalent forms: a non-iterative conditional expectation (NICE) form involving a single weighted average of conditional outcome means, and an iterative conditional expectation (ICE) form involving nested expectations. We illustrate both forms using three progressively complex numerical examples: a time-fixed example with a single binary confounder, a time-fixed example with discrete and continuous confounders, and a time-varying example with two timepoints. We provide clarity on what the law of iterated expectation is, how it is related to the g-formula, and how to gain intuition of its mathematical formulations in actual data examples that can be generalized to a range of settings.