Step 1 – modeling the problem
In this section, we’ll discuss and practice step 1 of the four-step causal inference process: modeling the problem.
We’ll split this step into two substeps:
- Creating a graph representing our problem
- Instantiating DoWhy’s
CausalModel
object using this graph
Creating the graph
In Chapter 3, we introduced a graph language called GML. We’ll use GML to define our data-generating process in this section.
Figure 7.1 presents the GPS example from the previous chapter, which we’ll model next. Note that we have omitted variable-specific noise for clarity:
Figure 7.1 – The graphical model from Chapter 6
Note that the graph in Figure 7.1 contains an unobserved variable, U. We did not include this variable in our dataset (it’s unobserved!), but we’ll include it in our graph. This will allow DoWhy to recognize that there’s an unobserved confounder...