View source: R/draw_causal_type.R
draw_causal_type | R Documentation |
Output is a parameter dataframe recording both parameters (case level priors) and the case level causal type.
draw_causal_type(model, ...)
model |
A |
... |
Arguments passed to 'set_parameters' |
# Simple draw using model's parameter vector
make_model("X -> M -> Y") %>%
draw_causal_type(.)
# Draw parameters from priors and draw type from parameters
make_model("X -> M -> Y") %>%
draw_causal_type(., param_type = "prior_draw")
# Draw type given specified parameters
make_model("X -> M -> Y") %>%
draw_causal_type(., parameters = 1:10)
# Define a causal type and reveal data
model <- make_model("X -> Y; X <-> Y")
type <- model %>% draw_causal_type()
make_data(model, parameters = type$causal_type)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.