Identify a causal effect of the form \(P(y|do(x),z)\) from \(P(v)\) in \(G\).
causal_effect(g, y, x = character(0), z = character(0), v = integer(0))An object of class query which is a list with the following
components:
id
A logical value that is TRUE if the query is identifiable and
FALSE otherwise.
formula
A functional object expressing the causal effect in terms
of the joint probability distribution \(P(v)\) for identifiable queries
or NULL if the query is not identifiable.
data
The available data, for causal_effect this is always
"observations"
causaleffect
The original query \(P(y|do(x),z)\) as a probability
object.
undefined
A logical value, this is always FALSE for
causaleffect
A dag object depicting the causal diagram \(G\).
A character vector of response variables \(Y\).
A character vector of intervention variables \(X\).
An optional character vector of conditioning variables \(Z\).
An optional named integer vector giving the value assignments
for observed variables in the model, i.e. \(V = v\) or
for a subset of \(V\).