Generate a statement for X1, X1 interact 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()
,
non_decreasing()
,
non_increasing()
,
substitutes()
,
te()
Examples
# \donttest{
interacts('A', 'B', 'W')
#>
#> Statement:
#> ((W[A =1, B = 1]) - (W[A = 0, B = 1])) != ((W[A =1, B = 0]) - (W[A = 0, B = 0]))
get_query_types(model = make_model('X-> Y <- W'),
query = interacts('X', 'W', 'Y'), map = "causal_type")
#>
#> Causal types satisfying query's condition(s)
#>
#> query = ((Y[X=1,W=1])-(Y[X=0,W=1]))!=((Y[X=1,W=0])-(Y[X=0,W=0]))
#>
#> W0.X0.Y1000 W1.X0.Y1000
#> W0.X1.Y1000 W1.X1.Y1000
#> W0.X0.Y0100 W1.X0.Y0100
#> W0.X1.Y0100 W1.X1.Y0100
#> W0.X0.Y0010 W1.X0.Y0010
#> W0.X1.Y0010 W1.X1.Y0010
#> W0.X0.Y0110 W1.X0.Y0110
#> W0.X1.Y0110 W1.X1.Y0110
#> W0.X0.Y1110 W1.X0.Y1110
#> W0.X1.Y1110 W1.X1.Y1110
#> W0.X0.Y0001 W1.X0.Y0001
#> W0.X1.Y0001 W1.X1.Y0001
#> W0.X0.Y1001 W1.X0.Y1001
#> W0.X1.Y1001 W1.X1.Y1001
#> W0.X0.Y1101 W1.X0.Y1101
#> W0.X1.Y1101 W1.X1.Y1101
#> W0.X0.Y1011 W1.X0.Y1011
#> W0.X1.Y1011 W1.X1.Y1011
#> W0.X0.Y0111 W1.X0.Y0111
#> W0.X1.Y0111 W1.X1.Y0111
#>
#>
#> Number of causal types that meet condition(s) = 40
#> Total number of causal types in model = 64
# }