June 11, 2026
Causal discovery aims to identify causal relationships among variables from observational or interventional data, typically represented by a directed acyclic graph (DAG). The causal invariance principle enables the identification of the causal parents of target variables by exploiting the stability of causal effects across different experimental settings. When some parents are unobserved, however, the induced graph over the observed variables may no longer be a DAG, and it may not be unique, complicating causal inference. For relevant configurations of latent parents, we characterize the induced graph and formalize the conditions under which causal invariance is preserved for the identification of the observed parents. Necessary and sufficient conditions for testing such invariance are formally established for a multivariate Gaussian target.
Causal directed acyclic graphs (DAGs) are extensively used to represent the structural causal model of data generating processes. In these graphs, the nodes correspond to random variables and causal relationships are encoded by directed edges, where \(X \rightarrow Y\) implies that \(X\) is a causal parent of \(Y\) [1]. Identifying the set of causal parents \(X_{PA}\) of a target \(Y\) requires an inferential procedure known as causal discovery. Invariant Causal Prediction (ICP), introduced by [2], is a recent method for parent search based on the idea that causal effects remain invariant across different experimental settings, referred to as environments. Given data sampled from these settings, the method consists in testing the invariance of the conditional distribution of \(Y\) given \(X_S\) across environments for all subsets \(X_S\) of the predictor set \(X_V=\{X_i\}_{i=1}^p\). When all causal parents are observed, the intersection of the subsets \(X_S\) that satisfy the invariance hypothesis belongs to \(X_{PA}\) with controllable probability.
In the absence of causal sufficiency, that is when some parents are unobserved in the generating DAG, testing causal invariance may fail because hidden variables induce distortions, confounding, and identifiability issues. Related approaches, such as causal Dantzig [3], provide closed-form estimators of causal effects under the more restrictive setting of structural equation models with additive perturbations and allow correlated independent errors for potential hidden variables. [4] extend this method by introducing efficient hybrid estimators that make use of instrumental variables for model identifiability. Alternative approaches focus on robust prediction methods under distributional shifts [5]–[7]. The impact of latent structures in testing causal invariance for parent identification requires further investigation as pointed out recently by [5].
We approach this issue by investigating whether the identification of the parent set can be recovered by the graphical model induced over the observed variables. More specifically, the general question behind this paper is whether the graph induced over the observed variables enables one to specify the structural causal model of a target \(Y\) after integrating out the latent variables. This is an ambitious question as characterizing the graphical causal model for the observed variables is far from straightforward. The induced graph may no longer be a DAG and mixed graphs with further bi-directed edges are often needed to encode the intricate dependence structures arising after marginalizing over the latent variables [8]. Additionally, depending on the graphical marginalization criterion adopted [9], [10], the induced graph and the resulting parent sets for \(Y\) may not be unique, thereby complicating causal parent identification.
In this paper, we provide an answer to this question under certain latent configurations. In particular, we consider closely the cases when unobserved parents act either as a transition node, \(X \rightarrow H \rightarrow Y\), or as a source node, \(X \leftarrow H \rightarrow Y\) along the causal path, which are the cases of hidden mediator and hidden counfounder, respectively (first row of Figure 1). We first characterize the graphical model for the observed variables such that causal invariance is preserved for the distribution of a target of interest conditional on the observed parents. Then, we develop a framework for testing such invariance when the target is a multivariate Gaussian variable; the univariate Gaussian target represents a special case. Empirical examples illustrate how the method can recover causal parents under these latent structures. Extended proofs and technical details are deferred to the Appendix.
Let us consider a DAG \(\mathcal{D}=(V,E)\), representing the generating process for a set \(X_V=\{X_i\}_{i \in V}\) of random variables, where each \(X_i\) is associated to a node of the graph and \(E\) is the set of directed edges. A DAG model is an independence model for \(X_V\) where conditional independences are implied by \(d\)-separation in the associated graph. A causal DAG model, where the arrows imply causal relationships, is defined by an additional assumption of invariance, or stability, of the conditional distribution of each node \(X_i\) given its causal parents \(X_{PA_i}\) under an intervention on all or a subset of \(X_{PA_i}\) [1]. If we represent the model via the structural causal model \[\label{SEM} X_i = f_i(X_{PA_i}, \delta_i), \quad \forall i \in V,\tag{1}\] where \(f_i\) is a deterministic function, \(X_{PA_i}\) are the causal parents of \(X_i\) in the graph and \(\delta_i\) are independent random errors, causal invariance refers to the invariance of \(f_i\) and of the distribution of \(\delta_i\) under intervention. We concentrate here on a target variable \(Y \in X_V\) and on the identification of its causal parents \(X_{PA}\). The invariance principle implies that if an external intervention is applied on, say, all causal parents of \(Y\), by setting these to values \(x_{PA}\), then \[p(Y \vert \text{do}(X_{PA}=x_{PA}))=p(Y \vert X_{PA}=x_{PA}),\] that is, the distribution of \(Y\) post-intervention, denoted using the -operator, is the same as the conditional distribution of \(Y\) when \(X_{PA}\) are simply observed to take the value \(x_{PA}\). The same definition can be given for a multivariate target \(Y=\{Y_j\}_{j=1}^m\) where \(X_{PA}= \cup_{j=1}^m X_{PA_j}\) and \(X_{PA_j}\) is the parent set of \(Y_j\).
Since external interventions are often unethical or unfeasible, [2] and related approaches for general response types [11], [12] exploit the heterogeneity of datasets across different environments \(e \in \mathcal{E}\) to mimic the effect of an external distributional intervention on \(X_V\) without actually performing it. Under the assumption of no intervention on \(Y\), they provide an inferential procedure for parent identification based on testing the invariance condition using the data collected in different environments.
Definition 1. Consider a set of data \((Y^e, X^e)\) collected from different experimental settings \(e \in \mathcal{E}\), where \(Y^e\) is a (multivariate) target variable which is not subject to interventions and \(X^e\) represents a set of predictors. Let \(Y^e = f(X_{PA}^e, \delta_Y^e)\) be the structural equation for the target for each \(e \in \mathcal{E}\). The conditional distribution \(p(Y \vert X_{PA})\) is invariant if: (i) \(f\) is the same \(\forall e \in \mathcal{E}\), (ii) the distribution of \(\delta_Y^e\) is the same for each \(e \in \mathcal{E}\) and (iii) \(\delta_Y^e \: \perp \perp X_{PA}^e\).
Intuitively, testing invariance corresponds to verifying that the conditional distributions \(Y^e \vert X_{PA}^e=x_{PA}^e\) and \(Y^{e'} \vert X_{PA}^{e'}=x_{PA}^{e'}\) are equal for all environments \(e,{e'} \in \mathcal{E}\), which mimic an external intervention at least on the parent set in order to ensure their correct identification.
We now consider causal DAGs in which some of the causal parents of the target variables \(Y\) are unobserved. When adequate a priori information is lacking and imposing probabilistic assumptions on the latent structures is too restrictive, working with the marginal distribution of the observed variables becomes a desirable alternative. The graph for the observed variables may no longer be a DAG, since this class is not closed under marginalization. A larger class of graphs is then needed. This class includes additional bi-directed edges to represent the dependence induced between two observed variables by latent common causes.
In particular, we consider the class of acyclic directed mixed graphs [10] (henceforth, mixed graphs) in which nodes may be linked by multiple directed and bi-directed edges that capture the effect of latent structures. Such graphs and related models have been employed to estimate causal effects in the presence of latent variables in [13]. As an example, the second row of Figure 1 displays the mixed graphs induced by the latent parent configurations in the first row. When a transition variable \(H\) is ignored (Figures 1 (a) and (b)), as typical in mediation analysis, the induced mixed graph remains a DAG, since ignoring a transition node yields a directed edge between the observed variables. Note that \(X\) becomes a parent of \(Y\) in graph (e) even though it is an ancestor in the generating DAG (a). When the latent parent is a source node (Figures 1 (c) and (d)), the induced mixed graph is not a DAG. In particular, ignoring \(H\) in DAG (c) yields no directed relationship between \(Y\) and \(X\) in the induced graph (g), while in the mixed graph (f) the multiple edges between \(Y\) and \(X\) enable one to account for the confounding effect, distinguishing the direct effect of \(X\) from the non-direct dependence induced by \(H\) in DAG (d).
Graphical mixed models are ruled by the \(m\)-separation criterion that generalizes the \(d\)-separation criterion for mixed graphs [10]. The resulting model is a structural equation model with dependent errors and further dependences stemming from latent variables. Let \(\mathcal{G}=(V, E)\) be a mixed graph associated with a random vector \(X_V\), and let the model in 1 hold for any \(X_i \in X_V\). Unlike DAGs, \(\delta_i \: \perp \perp / \delta_j\) if \(X_i\) and \(X_j\) are linked by a bi-directed edge (\(X_i \leftrightarrow X_j\)). Moreover, if \(i \in PA_j\) such that the nodes are linked by multiple edges \((X_i \mathrel{\substack{\longleftrightarrow \\[-0.5ex] \longrightarrow}} X_j)\), then \(\delta_j \: \perp \perp / X_{PA_j}\). For instance, the structural equation model associated to the mixed graph in Figure 1 (h) is \[\begin{align} Y = f_Y(X, \delta_Y), \quad X = f_X(Z, \delta_X), \quad Z =\delta_Z, \qquad \delta_Y\: \perp \perp/ \delta_X, \; \; \delta_Y\: \perp \perp/ X. \end{align}\] Instead, the model associated to the mixed graph in Figure 1 (g) is defined by the equations \[\begin{align} Y = \delta_Y, \quad X = f_X(Z, \delta_X), \quad Z =\delta_Z, \qquad \delta_Y\: \perp \perp/ \delta_X. \end{align}\] The implications that marginalization over the latent variables has on causal invariance and, therefore, whether causal discovery can still be conducted on the statistical model associated to the induced mixed graph are central questions to this paper. In particular, given a causal DAG with latent parents, we characterize the structural causal model for the target variable in the induced mixed graph and we formalize the testing of causal invariance for the identification of the observed parents when the target is Gaussian. Causal graphical models without and with hidden confounders are considered, respectively, in Sections 3 and 4.
Let \(X\in \mathbb{R}^p\) be a set of predictors, \(H \in \mathbb{R}^q\) a set of latent variables and \(Y \in \mathbb{R}^m\) a multivariate response whose parent sets of observed and unobserved variables are \({X}_{PA}\) and \(H_{PA}\), respectively. The parents of \(H_{PA}\) are denoted with \(X_{PA(H)}\) instead. Based on a data generating DAG mechanism, let the model of \(Y\) and of the latent parents \(H_{PA}\) follow the causal equations \[\label{eq:SCM-transition-source} Y = f(X_{PA}, H_{PA}, \delta_Y), \quad H_{PA} = g(X_{PA(H)}, \delta_H), \qquad \delta_{Y}\: \perp \perp \{{X}_{PA}, H_{PA}\}, \; \;\; \delta_H\: \perp \perp \delta_Y,\tag{2}\] with \(\delta_{Y} \sim F_{\delta_{Y}}\) for some distribution \(F_{\delta_{Y}}\). The latent variables in \(H_{PA}\) act as transition and/or source node along the paths to \(Y\) without confounding effects, such that \(\varepsilon_Y \: \perp \perp X_{PA}\). Interventions do not affect the unobserved variables, as well as the target variables. Therefore, the distributions of both \(Y|X_{PA}\) and \(H_{PA}|X_{PA(H)}\) are invariant, since (2 ) is a structural causal model.
Marginalizing over \(H\) leads to a mixed graph for the observed variables where, ignoring a transition latent parent \(H_l\) along the causal path to \(Y_j\), induces a directed edge such that the parents of \(H_l\) become parents of \(Y_j\), while ignoring a source latent parent \(H_l\) induces bi-directed edges linking its child nodes. Figures 1 (a)-(c) and Figures 1 (e)-(g) are illustrative of the marginalization criterion for a single target. No multiple edges arise in the induced graph since there are no confounding effects. Under these latent configurations, the induced mixed graph is equivalent to an ancestral graph [9], which is another notable class of graphs used to represent the marginal distribution of DAGs with hidden variables, using a different marginalization criterion.
The model for \(Y\) given the observed variables corresponds to the structural equation model \[\label{structural32causal32model32without32HC} Y =\tilde{f}(X_{\widetilde{PA}}, \varepsilon_{Y}), \qquad \varepsilon_{Y}\: \perp \perp {X}_{\widetilde{PA}},\tag{3}\] for an error term \(\varepsilon_Y \sim F_{\varepsilon_y}\) and some function \(\tilde{f}\) where \(X_{\widetilde{PA}}=X_{PA} \cup X_{PA(H)}\) is the augmented parent set. The next proposition proves that the marginal model in 3 is a structural causal model for \(Y\) and the marginal mixed graph can be given a causal interpretation for the target \(Y\).
Proposition 1. The marginal model in 3 is a structural causal model, then the conditional distribution of \(Y \vert X_{\widetilde{PA}}\) is invariant.
The above result proves that ignoring source variables does not induce causal relationships among the observed variables. On the other hand, when mediator/transition variables are not observed, the stability of the causal mechanism that links the augmented parents \(X_{\widetilde{PA}}\) to the target \(Y\) is preserved as no intervention is made on the latent variables. In case of hidden confounding such that \(X_{PA} \: \perp \perp / \delta_H\) in 2 , Proposition 1 no longer holds, as will be discussed in detail in Section 4.
Given the mixed graph and the related structural causal model 3 for \(Y\), the next Theorem provides a necessary and sufficient condition for testing causal invariance for any subset \(X_S \subseteq X\) in a linear model with Gaussian target variables \(Y\).
Theorem 1. Let \(Y =B^T_{{PA}}X + \varepsilon_{Y}\) be a linear structural equation for the target \(Y\), for some coefficient matrix \(B_{{PA}} \in \mathbb{R}^{p \times m}\) where \((B_{{PA}})_{ij}=0\) if and only if \(X_i \not \in X_{\widetilde{PA}_j}\) with \(X_{\widetilde{PA}_j}\) the set of observed parent variables of \(Y_j\) in the induced mixed graph. Assume \(\varepsilon_{Y} \sim N(0, \Sigma)\) for some covariance matrix \(\Sigma\) and \(\varepsilon_{Y} \: \perp \perp X_{\widetilde{PA}}\). Let \(S_j \subset \{1,\dots,p\}\) be a set of potential causal parents for \(Y_j \in Y\) with \(S=\bigcup_{j=1}^{m}S_j\). Let \(B \in \mathbb{R}^{p \times m}\) such that \(B_{ij}=0\) if and only if \(X_i \not \in S_j\) and that solves the expected likelihood score equations \[\label{ortogonalità} \mathbb{E}_{{X}_{S},{Y}}[({Y} - B^T{X}){X}_{S}^T]=0.\qquad{(1)}\] Then, \(S=\widetilde{PA}\) and \(B=B_{PA}\) almost surely if and only if \(\mathbb{E}_{X,Y}[(Y - B^T X)(Y - B^T X)^T] = \Sigma\).
Theorem 1 can be exploited in order to build an inferential procedure for recovering the parent set of a given target variable. The proposed procedure considers all possible subsets \(X_S \subseteq X\), and for each of these, tests the invariance condition \[\label{H0} H_0 : \Sigma_1=\dots=\Sigma_k\tag{4}\] from data across the \(k\) environments \(e \in \mathcal{E}\). To give an empirical illustration of this procedure, we employ Box’s M test using the test statistic \[M = (n-k)\log |\hat{\Sigma}| - \sum_{e=1}^{k}(n_e-1) \log |\hat{\Sigma}_e|,\] with \(\hat{\Sigma}^e\) the unbiased \(m\times m\) sample covariance matrix of the residuals of a multivariate linear regression model predicting the response using data from environment \(e\) and \(\hat{\Sigma}= \frac{1}{n-k}\sum_{e=1}^{k}(n_e - 1) \hat{\Sigma}_e\) the pooled covariance, with \(n_e\) denoting the sample size of environment \(e\) and \(n=n_1+\dots+n_k\) the total sample size. Setting \(c=\frac{2m^2 + 3m -1}{6(m+1)(k-1)}\left(\sum_{e=1}^{k}\frac{1}{n_e -1}- \frac{1}{n-k} \right)\), under the null hypothesis, \[M(1-c) \overset{H_0}{\sim} \chi^2_{\nu}, \quad \nu = (k-1)m(m+1)/2.\] At the significant level \(\alpha\), we expect the invariance condition 4 to be accepted for more than one subset \(S\), as non-predictive variables can be included in any invariant set while preserving invariance. For this reason, among all sets for which the null hypothesis cannot be rejected, we select the one that minimizes the average Bayesian Information Criterion (BIC) across environments.
We provide a numerical example to demonstrate that the causal parents of a target variable in an induced mixed graph are effectively identified when applying the result of Theorem 1 to test for invariance. Let us consider the data generating model for a bivariate Gaussian target \(Y=\{Y_1,Y_2\}\) represented by the causal DAG in Figure 2 (a) including eight observed variables \(X=\{X_1,\dots, X_8\}\) and three latent variables \(H=\{H_1,H_2,H_3\}\). Specifically, \(H_1\) is a latent transition parent for the outcome \(Y_1\); \(H_3\) acts simultaneously as a latent transition parent for \(Y_2\) and a source node for \(X_4\) and \(Y_2\); \(H_2\) is a common source node for the two outcomes. The induced mixed graph over the observed variables, shown in Figure 2 (b), includes the bi-directed edges \(Y_1 \leftrightarrow Y_2\) and \(X_4 \leftrightarrow Y_2\) that are non-causal relationships, and directed edges \(X_3 \rightarrow Y_1\), \(X_2 \rightarrow Y_2\), so that \(X_2,X_3\) enter the augmented causal parent set of \(Y_1,Y_2\). Section 8.1 of the Appendix provides a detailed description of the structural causal model and the generation of data from two environments, which mimic multiplicative interventions. In each environment, data were simulated with a sample size of \(n=500\). The parent set \(\{X_1, X_2,X_3, X_5\}\) of the joint outcome \(\{Y_1, Y_2\}\) in Figure 2 (b) is correctly identified \(92\%\) of times across \(50\) Monte Carlo replications using a 5% significance level for the tests.
We frame the proposed procedure within the setting of causal models with hidden confounders, which typically make causal effects non-identifiable. Given the variable structure described in Section 3, we further assume that a set of instrumental variables \(Z \in \mathbb{R}^r\) are available to ensure model identifiability in correspondence of confounding effect [14]. Based on a generating DAG, we consider the structural causal model for \(Y\), \(H_{PA}, X_{PA}\) \[\label{structural32causal32model} Y = f(X_{PA}) + g(H_{PA}, \delta_{Y}), \qquad H_{PA} = \delta_H, \qquad X_{PA} = l(H_{PA}, Z, \eta)\tag{5}\] with \(\delta_Y \: \perp \perp \{X_{PA}, H_{PA} \}\), \(\delta_H \: \perp \perp \delta_Y\), \(\eta \: \perp \perp \{H, Z \}\), \(Y \: \perp \perp Z \vert X_{PA}\), \(\mathbb{C}ov(Z, X_{PA}) \not = 0\) and \(\delta_Y \sim F_{\delta_Y}\) for some distribution \(F_{\delta_Y}\). As interventions do not affect \(\{H_{PA},Y\}\), the distribution of \(Y|\{X_{PA}, H_{PA}\}\) is invariant. The set \(H_{PA}\) may involve confounding. All latent parents are assumed to be exogenous (\(X_{PA(H)}= \emptyset)\), consequently there are no latent parents acting as transition nodes for \(Y\). If we marginalize over \(H_{PA}\), we get a mixed graph \(\mathcal{G}\) with additional bi-directed edges linking \(Y_j\) and its parents \(X_i \in X_{PA_j}\) in correspondence of confounding effect. Figures 1 (d) and (h) are illustrative of for the case of a single target. The mixed graph includes multiple edges to distinguish between the direct effect of parent variables on a target and the further confounding effect. The induced model for \(Y\) given the observed variables is the structural equation model \[\label{structural32causal32model32with32HC} Y =f(X_{PA}) + \varepsilon_{Y}, \quad X_{PA}= \tilde{l}(Z, \eta), \quad \varepsilon_{Y}\: \perp \perp/ X_{PA},\tag{6}\] with an error term \(\varepsilon_Y \sim F_{\varepsilon_Y}\). In this setting, we prove that in the induced mixed graph, parents of \(Y\) are causal parents under the weak invariance principle, and that the structural equation in 6 is a causal model for a target \(Y\). We recall the definition of weak invariance [2].
Definition 2. If the multivariate random variable \(Y\) follows the causal equation \(Y^e = f(X_{PA}^e, \varepsilon_Y^e)\) for all \(e \in \mathcal{E}\), then we say that the distribution of \(Y\vert X_{PA}\) satisfies the weak invariance property if conditions (i) and (ii) of Definition 1 hold.
Intuitively, the weak invariance condition represents a softer form of regularity that holds even if hidden confounders are present. We exploit this definition in order to give a causal interpretation to marginal mixed graph models also when this type of latent configuration occurs.
Proposition 2. The marginal model in 6 is a structural causal model, then the conditional distribution of \(Y \vert X_{PA}\) is weakly invariant.
Note that the induced mixed graph for a DAG including confounding effects may be not equal to the induced ancestral graph [9]. In fact, given the DAG in Figure 1 (d), the induced ancestral graph does not have the bi-directed edge between \(X\) and \(Y\). Instead, it has a directed arrow from \(Z\) to \(Y\), making \(Z\) an additional parent of the target variable. Even though the ancestral and mixed graph models are equivalent in terms of independences, the next proposition shows that the ancestral graph model is not invariant for \(Y\). The proof in Section 7 of the Appendix is complemented with a brief discussion on the comparison between the induced mixed and ancestral graph model.
Proposition 3. Consider the causal DAG in Figure 1 (d). In the induced ancestral graph obtained by ignoring the latent variable \(H\), the weak invariance property does not hold for \(p(Y \vert X, Z)\).
In a more general setting where the latent parents can also act as transition nodes, we prove that causal invariance holds when the effect of \(H_{PA}\) on \(Y\) is linear. Then, we consider the model \[\label{structural32causal10model32version322} Y = f(X_{PA}) + \Gamma_{PA}^TH + \delta_{Y}, \quad H_{PA} = g(X_{PA(H)}) + \delta_H, \quad X_{PA} = l(H, Z, \eta)\tag{7}\] with \(\delta_Y \: \perp \perp \{X_{PA}, H_{PA} \}\), \(\delta_H \: \perp \perp X_{PA(H)}\), \(\delta_H \: \perp \perp \delta_Y\), \(\eta \: \perp \perp \{H, Z \}\) and \(\delta_Y \sim F_{\delta_Y}\). \(\Gamma_{PA} \in \mathbb{R}^{q \times m}\) is a coefficient matrix with \((\Gamma_{PA})_{lj}=0\) if and only if \(H_l \not \in H_{PA_j}\). The induced model for \(Y\) is \[\label{structural32causal32model32with32HC32version322} Y =f(X_{\widetilde{PA}}) + \varepsilon_{Y}, \quad X_{\widetilde{PA}}= \tilde{l}(Z, \eta), \quad \varepsilon_{Y}\: \perp \perp/ X_{\widetilde{PA}},\tag{8}\] where \(\varepsilon_Y \sim F_{\varepsilon_Y}\) and the parent set \(X_{\widetilde{PA}}\) can be larger than \(X_{PA}\) in case of latent transition parents.
Proposition 4. The marginal model in 8 is a structural causal model, then the conditional distribution of \(Y \vert X_{\widetilde{PA}}\) is weakly invariant.
Given Proposition 4, invariance conditions are now derived for the case of a Gaussian target.
We now specify the structural causal model in [structural causal model version 2] for a Gaussian target \[\label{linear32SCM} Y= \Lambda_{PA}^TX + \Gamma_{PA}^TH + \delta_Y, \quad H_{PA} = \Phi_{PA}^TX + \delta_H,\tag{9}\] with \(\delta_Y \sim N(0, \Omega)\) for a diagonal covariance matrix \(\Omega\) and where the non-zero entries in the matrices \(\Lambda_{PA}, \Gamma_{PA}, \Phi_{PA}\) identify the parent sets \(X_{PA}\), \(H_{PA}\) and \(X_{PA(H)}\). Given \(B_{PA}^T = \Lambda_{PA}^T + \Gamma_{PA}^T\Phi_{PA}^T\) and \(\varepsilon_Y = \Gamma_{PA}^T\delta_H + \delta_Y\), the causal equation for \(Y\) ignoring \(H_{PA}\) becomes \[\label{linear32SCM32with3232HC} Y = B_{PA}^TX + \varepsilon_Y, \qquad \varepsilon_Y \sim N(0, \Sigma)\tag{10}\] where \(\varepsilon_Y \: \perp \perp / X_{\widetilde{PA}}\) if any hidden confounder is present. The next theorem provides a necessary and sufficient condition for testing weak causal invariance for any subset \(X_S \subseteq X\) in 10 .
Theorem 2. In the above linear setting, let \(S_j \subset \{1,\dots,p\}\) be a set of potential causal parents for \(Y_j \in Y\) with \(S=\bigcup_{j=1}^{m}S_j\). Let \(B \in \mathbb{R}^{p \times m}\) such that \(B_{ij}=0\) if and only if \(X_i \not \in S_j\) and that solves the expected likelihood score equations \[\mathbb{E}_{{X}_{S }, {Y}}[({Y} - B^T {X}) {X}_S^T]= \Gamma_{PA}^T\mathbb{E}_{{X}_{S }, {\delta}_{H}}[\delta_H {X}_S^T], \; \;\; \mathbb{E}_{{X}_{S }, {Y}, \delta_H}[({Y} - B^T {X}) \delta_H^T]= \Gamma_{PA}^T\mathbb{E}_{\delta_H}[\delta_H\delta_H^T].\] Then, \(S=\widetilde{PA}\) and \(B=B_{PA}\) almost surely if and only if \(\mathbb{E}_{{X}, {Y} }[({Y} - B^T {X} )({Y} - B^T {X} )^T] = \Sigma .\)
We provide a numerical illustration to show that by applying the result of Theorem 2 to test for invariance in mixed graph models with confounding effects, the causal parents of a target variable are effectively identified. To this end, we consider the data generating model represented by the causal DAG in Figure 3 (a). The model includes a bivariate Gaussian target \(Y=\{Y_1,Y_2\}\), eight observed variables \(X=\{X_1,\dots, X_8\}\) and five latent variables \(\{H_1,H_2,H_3,H_4, H_5\}\) serving as causal latent parents of \(Y\). In particular, the latent parents \(H_4\) and \(H_5\) act as hidden counfounders and the instrumental variables \(Z_1\) and \(Z_5\) are introduced to ensure the identifiability of the causal effects of \(X_1\) on \(Y_2\) and of \(X_5\) on \(Y_1\), respectively. The induced mixed graph over the observed variables, shown in Figure 3 (b), includes additional bi-directed edges with no causal interpretation and the directed edges \(X_3 \rightarrow Y_1\) and \(X_2 \rightarrow Y_2\), so that \(X_2\) and \(X_3\) enter the augmented causal parent set of \(Y_1,Y_2\). Data are sampled based on a data-generating model and from two environment mimic multiplicative intervention; for a detailed description see Section 8.2 of the Appendix. Using the testing procedure from Theorem 2 within the Monte Carlo simulation scheme described in Section 3, the parent set \(\{X_1, X_2, X_3, X_5\}\) in Figure 3 (b) is correctly identified in \(92\%\) of the cases across \(50\) replicates when \(n=1000\) and using a 5% significance level for the tests. On the other hand, the testing procedure based on the result of Theorem 1 identifies the correct causal parents only in \(18\%\) of the cases.
We consider the flow cytometry data of [15]. These data measure the abundance of 11 biochemical agents in different environments. The first of them can be considered as an observational environment, while the others are generated under the intervention of a certain reagent that modifies the abundance or the action of the biochemical agents.
We focus on the first observational environment and the one that corresponds to an abundance intervention on the agent PKC (due to the reagent PMA) in combination with a global intervention (see [16] and [17] for further details). We concentrate on the bivariate target {P38, Erk}, as these nodes are at the same level according to the consensus network in [15]. Firstly, we search for the causal parents of the bivariate target among all the possible subsets of the 9 remaining covariates, namely Raf, Mek, Plcg, PIP2, PIP3, Akt, PKA, PKC and Jnk, without considering the presence of confounders in the causal effects. In other words, we apply the procedure resulting from Theorem 1 for parent identification. The set \(\{\text{Jnk}, \text{PKC}, \text{Akt}\}\) is found as the parent set, with a p-value of \(0.60\) from the Box’s M test, and the causal model is represented by the graph in Figure 4a.
Suppose now that the variable Jnk is unobserved. As expected, the restricted set {PKC, Akt} no longer satisfies the invariance condition required by Theorem 1. Given that the consensus network shows a relationship between PKC and Jnk, it seems reasonable to assume that Jnk acts as a confounder of the effect of PKC on P38. We therefore apply the procedure for parent identification provided by Theorem 2, and employ PIP2, Plcg, Raf and Mek as instrumental variables to ensure the identifiability of the causal effect of PKC on P38. This choice is further justified by the consensus network, where these variables appear as the most predictive of PKC. In this second analysis, the invariance condition is satisfied for the pair {PKC, Akt} with \(p\)-value equal to 0.55 and the structural causal model is represented by the mixed graph in Figure 4 (b).
Testing causal invariance in the absence of causal sufficiency, and in particular under latent confounding, is challenging. Rather than imposing probabilistic assumptions on the latent structure, in this paper we approach this issue by working directly with the marginal distributions of the observed variables. By considering the structural model of the target variable in the induced acyclic directed mixed graph, we demonstrate that causal invariance is preserved for the observed parent set under specific latent configurations. Then, we derive the formal conditions for testing such invariance in the case of a multivariate Gaussian target. These results extend both the principle and the application of causal invariance to a broader class of models where hidden confounding is present. An interesting future research question is to investigate under what conditions testing causal invariance is feasible for the full set of observed variables rather than for a specific target.
Financial support was provided to the first and second author by the MUR-PRIN grant 2022 SMNNKY, CUP B53D23009470006, the MUR Department of Excellence project 2023-2027 ReDS ‘Rethinking Data Science’ - Department of Statistics, Computer Science, Applications - University of Florence. Veronica Vinciotti acknowledges funding from the the European Union - Next Generation EU, Mission 4 Component 2 - CUP C53D23002580006 (MUR-PRIN grant 2022SMNNKY).
Proof. We assume that data are collected from different environments and that the structural causal model 2 holds for every \(e \in \mathcal{E}\). We can rewrite the first equation as \(Y = f(X_{PA}, H_{PA}, \delta_Y) = f(X_{PA}, g(X_{PA(H)}, \delta_H), \delta_Y)\). Moreover, \[\mathbb{E}_{\delta_H}[Y] = \int f(X_{PA}, g(X_{PA(H)}, \delta_H), \delta_Y) p(\delta_H) d \delta_H =: \tilde{f}(X_{\widetilde{PA}}, \delta_Y)\] where (i) \(\tilde{f}\) is the same for all the environments because it depends only on \(f,g\), which are the same \(\forall e \in \mathcal{E}\) thanks to the invariance of \(Y \vert \{X_{PA}, H_{PA} \}\) and \(H_{PA} \vert X_{PA(H)}\), and on the distribution of \(\delta_H\), which does not change across the environments since no external interventions affect \(H_{PA}\), and finally since \(X_{PA} \: \perp \perp \delta_H\). Moreover, (ii) \(\delta_Y \: \perp \perp X_{\widetilde{PA}}\) and (iii) the distribution of \(\delta_Y\) is the same in all the environments for hypothesis. ◻
Proof. The first implication is immediate because if \(S=\widetilde{PA}\) and \(B=B_{PA}\) with probability 1, then \[\mathbb{E}_{{X},{Y}}[({Y} - B^T{X})({Y} - B^T{X})^T] = \mathbb{E}_{{X},{Y}}[({Y} - B_{PA}^T{X})({Y} - B_{PA}^T{X})^T] = \Sigma.\] We focus now on the other direction. First of all, the population log-likelihood function is \(l_{{X},{Y}}(B) = -\frac{1}{2} \cdot \left( {Y}-B^T{X}\right)^T \Sigma^{-1} \left( {Y}-B^T{X}\right).\) Let \({b}:=vec(B)=(\beta_1, \dots, \beta_m)^T \in \mathbb{R}^{pm}\). The column vector \(B^T{X}\) can be written as \(B^T{X}= vec(B^T {X})=vec({X}^TB)=(I_m \otimes {X})^Tvec(B)= (I_m \otimes {X})^T{b}\), where \(I_m\) is an identity matrix of size \(m\). Following [12], the population log-likelihood function can be expressed as \(l_{{X},{Y}}({b}) = -\frac{1}{2} \cdot \left( {Y}-(I_m \otimes {X})^T{b}\right)^T \Sigma^{-1} \left( {Y}-(I_m \otimes {X})^T{b}\right)\). The first derivative with respect to \({b}\) is equal to \(\frac{\partial l_{{X},{Y}}({b})}{\partial {b}} = (I_m \otimes {X}_S) \Sigma^{-1} \left( {Y}-(I_m \otimes {X})^T{b}\right)\) while the first derivative with respect to \(B^T\) is equal to \(\frac{\partial l_{{X},{Y}}({b})}{\partial {b}^T} = \left( {Y}-(I_m \otimes {X})^T{b}\right)^T \Sigma^{-1} (I_m \otimes {X}_S^T)\). The second derivative of the population log-likelihood function is \(\frac{\partial^2 l_{{X},{Y}}({b})}{\partial {b} \partial {b}^T} = -(I_m \otimes {X}_S) \Sigma^{-1}(I_m \otimes {X}_S^T)\). From the invariance condition, we know that \(\mathbb{E}_{ {X}, {Y}}[( {Y} - B^T {X})( {Y} - B^T {X})^T] = \Sigma\). The first term can be written as \[\mathbb{E}_{ {X}, {Y}}[( {Y} - B^T {X})( {Y} - B^T {X})^T] = \mathbb{E}_{ {X}_S}\left[ \mathbb{E}_{ {Y}}[( {Y} - B^T {X})( {Y} - B^T {X})^T \vert {X}_S] \right]\] and hence \(\mathbb{E}_{ {Y}}[( {Y} - B^T {X})( {Y} - B^T {X})^T \vert {X}_S] = \Sigma\) holds almost surely on the space of distributions on \({X}_S\). Multiplying by \(\Sigma^{-1}\) on both sides, we obtain \(\mathbb{E}_{ {Y}}[\Sigma^{-1}( {Y} - B^T {X})( {Y} - B^T {X})^T \Sigma^{-1}\vert {X}_S] = \Sigma^{-1}\). Multiplying now by the Kronecker product on the left by \((I_m \otimes {X}_S)\) and on the right by \((I_m \otimes {X}_S^T)\), we get \[\mathbb{E}_{ {Y}}[(I_m \otimes {X}_S)\Sigma^{-1}( {Y} - (I_m \otimes {X}_S) {b})( {Y} - (I_m \otimes {X}_S) {b})^T \Sigma^{-1}(I_m \otimes {X}_S^T)\vert {X}_S] =(I_m \otimes {X}_S) \Sigma^{-1}(I_m \otimes {X}_S^T).\] Finally, by taking the expectation with respect to \({X}_S\), \[\mathbb{E}_{ {X}_S, {Y}}\left[\frac{\partial l_{ {X}, {Y}}( {b})}{\partial {b}} \cdot \frac{\partial l_{ {X}, {Y}}( {b})}{\partial {b}^T}\right] = - \mathbb{E}_{ {X}_S}\left[\frac{\partial^2 l_{ {X}, {Y}}( {b})}{\partial {b} \partial {b}^T} \right].\] If we prove that \(\mathbb{E}_{ {X}_S, {Y}}\left[\frac{\partial l_{ {X}, {Y}}( {b})}{\partial {b}} \right] =0,\) then the Bartlett’s identity holds and thus \({Y} \; \vert {X} \sim N(B^T {X},\Sigma)\). This follows from the hypothesis \(\mathbb{E}_{ {X}_{S}, {Y}}[( {Y} - B^T {X}) {X}_{S}^T]=0\). Indeed, since \(\Sigma\) is symmetric and positive definite, if we multiply on the left by \(\Sigma^{-1}\) both sides we obtain \(\mathbb{E}_{ {X}_{S}, {Y}}[ \Sigma^{-1}( {Y} - B^T {X}) {X}_{S}^T]=0\). Moreover, \[\begin{align} & \mathbb{E}_{ {X}_{S}, {Y}}[ \Sigma^{-1}( {Y} - B^T {X}) {X}_{S}^T]=0 \Rightarrow \mathbb{E}_{ {X}_{S}, {Y}}[ {X}_{S} ( {Y} - B^T {X})^T \Sigma^{-1}]=0 \\ &\Rightarrow \mathbb{E}_{ {X}_{S}, {Y}}\left[ vec\left( {X}_{S} ( {Y} - B^T {X})^T \Sigma^{-1} \right) \right]=0 \Rightarrow \mathbb{E}_{ {X}_{S}, {Y}}\left[ (I_m \otimes {X}_{S}) vec\left( ( {Y} - B^T {X})^T \Sigma^{-1} \right) \right]=0 \\ &\Rightarrow \mathbb{E}_{ {X}_{S}, {Y}}\left[ (I_m \otimes {X}_{S}) vec\left( \Sigma^{-1}( {Y} - B^T {X}) \right) \right]=0 \Rightarrow \mathbb{E}_{ {X}_{S}, {Y}}\left[ (I_m \otimes {X}_{S}) \Sigma^{-1}( {Y} - B^T {X}) \right]=0\\ &\Rightarrow \mathbb{E}_{ {X}_S, {Y}}\left[\frac{\partial l_{ {X}, {Y}}( {b})}{\partial {b}} \right] =0. \end{align}\] Since the set \(\{B \in \mathbb{R}^{p \times m} : \mathbb{E}_{ {X}, {Y}}[( {Y} - B^T {X})( {Y} - B^T {X})^T] = \Sigma \}\) is a surface of dimension \(pm-m\) in the space \(\mathbb{R}^{pm}\), its Lebesgue measure in \(\mathbb{R}^{pm}\) is zero. Therefore, \(S=\widetilde{PA}\) and \(B=B_{PA}\) almost surely. ◻
Proof. We consider data coming from multiple environments and we assume that for all \(e \in \mathcal{E}\) they are generated from the structural causal model 5 . As \(H_{PA}= \delta_H\) is exogenous, we rewrite the first equation as \(Y= f(X_{PA}) + g(\delta_H, \delta_Y) = f(X_{PA}) + \varepsilon_Y\) by defining \(\varepsilon_Y := g(\delta_H, \delta_Y)\). Then, (i) \(f\) is the same across the environments thanks to the invariance of the distribution of \(Y \vert \{ X_{PA}, H_{PA} \}\). Moreover, (ii) the distribution of \(\varepsilon_Y\) is the same for all \(e \in \mathcal{E}\). Indeed, the distribution of \(\varepsilon_Y\) is completely determined by \(g\), which is the same across the environments for hypothesis and by \(\delta_H\), which does not change because the external interventions are not performed on \(H_{PA}\). Moreover, the marginal distribution of \(\varepsilon_Y\) over \(\delta_H\) is the same for all \(e \in \mathcal{E}\) because \(\delta_Y \: \perp \perp \delta_H\). ◻
Proof. We show a counter example. We consider a generic linear structural causal model associated to the DAG in Figure 1 (d) where \(H\) is an unobserved counfounder between \(X\) and \(Y\) \[\label{SCM32432variables} Z = \delta_Z, \quad H = \delta_H, \quad X = \lambda_{xz}Z + \gamma_{xh}H + \delta_X, \quad Y = \lambda_{yx}X + \gamma_{yh}H + \delta_Y\tag{11}\] where \((\delta_Z, \delta_H, \delta_X, \delta_Y) \sim N( {0}, \Omega)\) with \(\Omega = diag(\omega_{zz}, \omega_{hh}, \omega_{xx}, \omega_{yy})\). We assume data are collected from two environments \(e\) and \(e'\), where \(\omega_{xx}^{e} \not = \omega_{xx}^{e'}\), while the distributions of \(H\) and of \(Y \vert X, H\) remain the same. The structural equation for \(Y\) in the induced ancestral graph model is \[Y = \beta_{yz \vert x}Z + \beta_{yx \vert z}X + \varepsilon_Y\] for some coefficients \(\beta_{yz \vert x}\) and \(\beta_{yx \vert z}\) and error term \(\varepsilon_Y\). But \(\beta_{yx \vert z}= \frac{\mathbb{C}ov(X,Y \vert Z)}{\mathbb{V}ar(X \vert Z)} = \lambda_{yx} + \frac{\gamma_{xh}\gamma_{yh}\omega_{hh}}{\gamma_{xh}^2\omega_{hh} + \omega_{xx}}\) and since we have assumed that the variance \(\omega_{xx}\) is different in the two environments (while all the other quantities remain the same), then \(\beta_{yx \vert z}^{e} \not = \beta_{yx \vert z}^{e'}\) so the invariance condition fails (as well as the weak invariance condition). It is easy to show that also the coefficient \(\beta_{yz \vert x}\) and the variance of \(\varepsilon_Y\) change in the two environments. ◻
For sake of completeness, we discuss that if we consider the induced mixed graph for the counter example used in the proof of Proposition 3, the model for \(Y\) satisfies the invariance principle, more specifically, the conditional distribution of \(Y \vert X\) is weakly invariant under the mixed graph model. Indeed, we assume data are collected from two environments \(e,e'\) and for both scenarios data are generated according to the structural causal model (11 ). Then, \(Y = \lambda_{yx}X + \gamma_{yh}\delta_H + \delta_Y = \lambda_{yx}X + \varepsilon_Y\), where \(\varepsilon_Y= \gamma_{yh}\delta_H + \delta_Y\). The mean of \(\varepsilon_Y\) is equal to zero in both \(e\) and \(e'\). Its variance is \(\mathbb{V}ar(\varepsilon_Y) = \gamma_{yh}^2\omega_{hh} + \omega_{yy}\). Therefore, if we do not intervene on \(Y\) and on \(H\), the distribution of \(\varepsilon_Y\) remains the same across the environments. Hence we can conclude that the distribution of \(Y \vert X\) is weakly invariant.
Proof. We assume that data are generated from different environments and that for each \(e \in \mathcal{E}\) the causal model [structural causal model version 2] is satisfied. We can write \[Y = f(X_{PA}) + \Gamma_{PA}^Tg(X_{PA(H)}) + \Gamma_{PA}^T \delta_H + \delta_Y = f(X_{PA}) + \Gamma_{PA}^Tg(X_{PA(H)}) + \varepsilon_Y\] where we have defined \(\varepsilon_Y := \Gamma_{PA}^T\delta_H + \delta_Y\). Then, thanks to the hypothesis, we have that (i) \(f(X_{PA}) + \Gamma_{PA}^Tg(X_{PA(H)})\) is the same for all \(e \in \mathcal{E}\). Moreover, by repeating the same argument as in the proof of Proposition 2, also (ii) the distribution of \(\varepsilon_Y\) is the same across the environments as well as its marginal distribution with respect to \(\delta_H\). ◻
Proof. The first implication is trivial, so we consider the other one. From the hypothesis we know that \(\mathbb{E}_{ {X}, {Y} }[( {Y} - B^T {X} ) ( {Y} - B^T {X} )^T] = \Sigma =\Gamma_{PA}^T\mathbb{E}_{\delta_H}[\delta_H \delta_H^T] \Gamma_{PA} + \Omega.\) Therefore, \[\begin{align} \mathbb{E}&_{ {X}, {Y}, \delta_H }[( {Y} - B^T {X} -\Gamma_{PA}^T\delta_H) ( {Y} - B^T {X} -\Gamma_{PA}^T\delta_H)^T]=\\ &= \mathbb{E}_{ {X}, {Y} }[( {Y} - B^T {X} ) ( {Y} - B^T {X})^T] -\mathbb{E}_{ {X}, {Y}, \delta_H }[( {Y} - B^T {X} )\delta_H^T]\Gamma_{PA} -\Gamma_{PA}^T\mathbb{E}_{ {X}, {Y}, \delta_H }[\delta_H( {Y} - B^T {X} )^T]+ \\ &+ \Gamma_{PA}^T\mathbb{E}_{\delta_H}[\delta_H\delta_H^T]\Gamma_{PA} = \Omega. \end{align}\] We rewrite the first population likelihood score equation as \(\mathbb{E}_{ {X}_{S }, {Y}, \delta_H}[( {Y} - B^T {X} - \Gamma_{PA}^T \delta_H) {X}_S^T]= {0}.\) Then, by repeating the same argument as in the proof of Theorem 1 with the last two results we obtain that \({Y} \vert {X}, \delta_H \sim N\left(B^T {X} + \Gamma_{PA}^T\delta_H, \Omega \right)\). Hence we get \({Y} = B^T {X} + \Gamma_{PA}^T\delta_H + \delta_Y = B^T {X} + \varepsilon_{ {Y}}\) with probability one. This thus implies that \(S=\widetilde{PA}\) and \(B=B_{PA}\) almost surely. ◻
This section describes the generating models of the numerical examples in Sections 3 and 4.
Given the causal DAG in Figure 2 (a), data are generated from the following structural causal model \[\begin{align} X_1^e &= \delta_{X_1}^e & X_2^e &= \lambda_{X_2,X_1} + \delta_{X_2}^e \\ X_3^e &= \delta_{X_3}^e & H_3^e &= \lambda_{H_3, X_2} X_2^e + \delta_{H_3}^e \\ X_4^e &= \lambda_{X_4,X_2}X_2^e + \gamma_{X_4, H_3}H_3^e + \delta_{X_4}^e & X_5^e &= \lambda_{X_5,X_1}X_1^e + \delta_{X_5}^e \\ H_1^e &= \lambda_{H_1,X_3}X_3^e + \delta_{H_1}^e & H_2^e &= \delta_{H_2}^e \\ X_6^e &= \lambda_{X_6, Y_1}Y_1^e + \delta_{X_6}^e & X_7^e &= \lambda_{X_7, Y_1}Y_1^e + \delta_{X_7}^e \\ X_8^e &= \lambda_{X_8, Y_2}Y_2^e + \delta_{X_8}^e & Y_1^e &= \lambda_{Y_1, X_5} X_5^e + \gamma_{Y_1,H_1}H_1^e + \gamma_{Y_1,H_2}H_2^e + \delta_{Y_1}^e \\ Y_2^e &= \lambda_{Y_2,X_1}X_1^e + \gamma_{Y_2,H_2}H_2^e + \gamma_{Y_2,H_3}H_3^e + \delta_{Y_2}^e \end{align}\] where the error terms \(\delta_{Y_i}^e, \delta_{X_j}^e, \delta_{H_r}^e \sim N(0,1)\) are all mutually independent and the regression coefficients are set to \(\lambda_{X_2,X_1}=1\), \(\lambda_{H_3, X_2}=2\), \(\lambda_{X_4,X_2}=-2.1\), \(\gamma_{X_4, H_3}=-1.7\), \(\lambda_{X_5,X_1} = 1.5\), \(\lambda_{H_1,X_3}=2\), \(\lambda_{Y_1, X_5}=-2.3\), \(\gamma_{Y_1,H_1} = 1.5\), \(\gamma_{Y_1,H_2} =-0.9\), \(\lambda_{Y_2,X_1}=3.2\), \(\gamma_{Y_2,H_2}=-1.3\), \(\gamma_{Y_2,H_3}=2.1\), \(\lambda_{X_6, Y_1}=3.3\), \(\lambda_{X_7, Y_1} = 2.4\), \(\lambda_{X_8, Y_2}=-1.6\). Data are simulated from an observational environment (\(e=1\)) and from an interventional one \((e=2)\). We consider multiplicative interventions, i.e., we set \(\delta_{X_j}^{e=2} = A_j\delta_{X_j}^{e=1}\) for some random variables \(A_j \sim N(2,1)\) which are mutually independent and also independent of all the error terms. We remark that we work under the assumption that the target and the latent variables are not subject to external interventions.
The induced mixed graph obtained after marginalizing over the latent variables is represented in Figure 2 (a) and, from Proposition 1, the related causal equations for \(Y_1\) and \(Y_2\) become \[\label{scm32Y132Y2} Y_1^e = \beta_{Y_1,X_3}X_3^e + \beta_{Y_1, X_5}X_5^e + \varepsilon_{Y_1}^e, \qquad Y_2^e = \beta_{Y_2,X_1}X_1^e + \beta_{Y_2, X_2}X_2^e + \varepsilon_{Y_2}^e\tag{12}\] where \(\beta_{Y_1,X_3}= \lambda_{H_1, X_3} \gamma_{Y_1, H_1} =3\), \(\beta_{Y_1, X_5}= \lambda_{Y_1,X_5}=-2.3\), \(\beta_{Y_2,X_1}=\lambda_{Y_2,X_1}=3.2\), \(\beta_{Y_2, X_2}= \lambda_{H_3, X_2} \gamma_{Y_2, H_3}= 4.2\), \(\varepsilon_{Y_1}^e = \gamma_{Y_1,H_1}\delta_{H_1}^e +\gamma_{Y_1,H_2}\delta_{H_2}^e + \delta_{Y_1}^e\) and \(\varepsilon_{Y_2}=\gamma_{Y_2,H_2}\delta_{H_2}^e + \gamma_{Y_2,H_3}\delta_{H_3}^e + \delta_{Y_2}^e\). Therefore, we have \(\varepsilon_{Y_1}^e\sim N(0, 4.06)\), \(\varepsilon_{Y_2}^e \sim N(0, 7.1)\) and \(\mathbb{C}ov(\varepsilon_{Y_1} \varepsilon_{Y_2})= 1.17\).
In this section we consider the generating DAG in Figure 3 (a) that includes different types of latent variables. The aim is to find the causal parents of the multivariate target \(\{Y_1,Y_2\}\) by using the more general result in Theorem 2. This procedure needs instrumental variables in order to overcome the possibility of non-identifiability of the model. We assume to have prior knowledge that the causal effects from \(X_1\) and from \(X_5\) can be confounded. We therefore consider the instrumental variables \(Z_1\) and \(Z_5\) for the predictors \(X_1\) and \(X_5\), respectively (see Figure 3). The associated causal model is \[\begin{align} Z_1^e &= \delta_{Z_1}^e, \; Z_5^e = \delta_{Z_5}^e & H_r^e &= \delta_{H_r}^e, \text{ for } r \in \{2,4,5\} \\ X_1^e &= \lambda_{X_1,Z_1}Z_1^e + \gamma_{X_1,H_5}H_5^e + \delta_{X_1}^e & X_2^e &= \lambda_{X_2, X_1}X_1^e + \delta_{X_2}^e \\ X_3^e &= \delta_{X_3}^e & H_3^e &= \lambda_{H_3,X_2}X_2^e + \delta_{H_3}^e \\ X_4^e &= \lambda_{X_4,X_2}X_2^e + \gamma_{X_4,H_3}H_3^e + \delta_{X_4}^e & X_5^e &= \lambda_{X_5,Z_5}Z_5^e + \gamma_{X_5,H_4}H_4^e + \delta_{X_5}^e \\ H_1^e &= \lambda_{H_1,X_3}X_3^e + \delta_{H_1}^e & X_6^e &= \lambda_{X_6, Y_1}Y_1^e + \delta_{X_6}^e \\ X_7^e &= \lambda_{X_7, Y_1}Y_1^e + \delta_{X_7}^e & X_8^e &= \lambda_{X_8, Y_2}Y_2^e + \delta_{X_8}^e \\ Y_1^e &= \lambda_{Y_1,X_5}X_5^e + \gamma_{Y_1,H_1}H_1^e + \gamma_{Y_1,H_2}H_2^e + \gamma_{Y_1,H_4}H_4^e + \delta_{Y_1}^e \\ Y_2^e &= \lambda_{Y_2,X_1}X_1^e + \gamma_{Y_2,H_2}H_2^e + \gamma_{Y_2,H_3}H_3^e + \gamma_{Y_2,H_5}H_5^e + \delta_{Y_2}^e \\ \end{align}\] where \(\lambda_{X_1, Z_1} = 1.5\), \(\gamma_{X_1,H_5}=2.1\), \(\lambda_{X_2, X_1}= 1\), \(\lambda_{X_4,X_2}=-2.1\), \(\gamma_{X_4,H_3} = -1.7\), \(\lambda_{X_5,Z_5}=1.5\), \(\gamma_{X_5,H_4}=1.9\), \(\lambda_{H_1,X_3}=2\), \(\lambda_{H_3,X_2}=2\), \(\lambda_{Y_1,X_5}=-2.3\), \(\gamma_{Y_1,H_1}=1.5\), \(\gamma_{Y_1,H_2}=-0.9\), \(\gamma_{Y_1,H_4}=-1.7\), \(\lambda_{Y_2,X_1}=3.2\), \(\gamma_{Y_2,H_2}=-1.3\), \(\gamma_{Y_2,H_3} = 2.1\), \(\gamma_{Y_2, H_5}=2.6\), \(\lambda_{X_6, Y_1}=3.3\), \(\lambda_{X_7, Y_1}=2.4\), \(\lambda_{X_8, Y_2}=-1.6\). As before, we consider multiplicative interventions. In particular, we set \(\delta_{X_j}^{e=2} = A_j\delta_{X_j}^{e=1}\) for some random variables \(A_j \sim N(2,2)\) which are mutually independent and also independent of all the error terms. The induced mixed graph obtained after marginalizing over the latent variables is shown in Figure 3 (b) and, from Proposition 4, the causal equations for \(Y_1\) and \(Y_2\) become \[Y_1^e = \beta_{Y_1,X_3}X_3^e + \beta_{Y_1,X_5}X_5^e + \varepsilon_{Y_1}^e, \qquad Y_2^e = \beta_{Y_2,X_1}X_1^e + \beta_{Y_2,X_2}X_2^e + \varepsilon_{Y_2}^e\] where \(\beta_{Y_1,X_3}= \gamma_{Y_1,H_1}\lambda_{H_1,X_3}=3\), \(\beta_{Y_1,X_5}= \lambda_{Y_1,X_5}=-2.3\), \(\beta_{Y_2,X_1}= \lambda_{Y_2,X_1}=3.2\), \(\beta_{Y_2, X_2}=\gamma_{Y_2,H_3}\lambda_{H_3,X_2}=4.2\), \(\varepsilon_{Y_1}^e = \gamma_{Y_1,H_1}\delta_{H_1}^e + \gamma_{Y_1,H_2}\delta_{H_2}^e + \gamma_{Y_1,H_4}\delta_{H_4}^e + \delta_{Y_1}^e\) and \(\varepsilon_{Y_2}^e=\gamma_{Y_2,H_2}\delta_{H_2}^e + \gamma_{Y_2,H_3}\delta_{H_3}^e + \gamma_{Y_2, H_5}\delta_{H_5}^e + \delta_{Y_2}^e\). Therefore, we have \(\varepsilon_{Y_1}^e\sim N(0, 6.95)\), \(\varepsilon_{Y_2}^e \sim N(0, 13.86)\) and \(\mathbb{C}ov(\varepsilon_{Y_1} \varepsilon_{Y_2})= 1.17\). In particular, \(\varepsilon_{Y_1} \: \perp \perp / X_5\) for the presence of the hidden confounder \(H_4\) and \(\varepsilon_{Y_2} \: \perp \perp / X_1\) for the presence of the hidden confounder \(H_5\).