Generate a statement for X1, X1 substitute for each other in the production of Y
Arguments
- X1
A character. The quoted name of the input node 1.
- X2
A character. The quoted name of the input node 2.
- Y
A character. The quoted name of the outcome node.
See also
Other statements:
complements()
,
decreasing()
,
increasing()
,
interacts()
,
non_decreasing()
,
non_increasing()
,
te()
Examples
# \donttest{
get_query_types(model = make_model('A -> B <- C'),
query = substitutes('A', 'C', 'B'),map = "causal_type")
#>
#> Causal types satisfying query's condition(s)
#>
#> query = ((B[A=1,C=1])-(B[A=0,C=1]))<((B[A=1,C=0])-(B[A=0,C=0]))
#>
#> A0.C0.B0100 A1.C0.B0100
#> A0.C1.B0100 A1.C1.B0100
#> A0.C0.B0010 A1.C0.B0010
#> A0.C1.B0010 A1.C1.B0010
#> A0.C0.B0110 A1.C0.B0110
#> A0.C1.B0110 A1.C1.B0110
#> A0.C0.B1110 A1.C0.B1110
#> A0.C1.B1110 A1.C1.B1110
#> A0.C0.B0111 A1.C0.B0111
#> A0.C1.B0111 A1.C1.B0111
#>
#>
#> Number of causal types that meet condition(s) = 20
#> Total number of causal types in model = 64
query_model(model = make_model('A -> B <- C'),
queries = substitutes('A', 'C', 'B'),
using = 'parameters')
#>
#> Causal queries generated by query_model (all at population level)
#>
#> |query |using | mean|
#> |:---------------------------------------------------------------------------------|:----------|-----:|
#> |((B[A = 1, C = 1]) - (B[A = 0, C = 1])) < ((B[A = 1, C = 0]) - (B[A = 0, C = 0])) |parameters | 0.312|
#>
# }