Make, Update, and Query Binary Causal Models
Helper to fill in missing do operators in causal expression
Create parameter documentation to inherit
'CausalQueries'
Helper to clean and check the validity of causal statements specifying...
make_par_values
make_par_values
make_par_values
Data helpers
Draw a single causal type given a parameter vector
Helper to expand nodal expression
Get all data types
helper to get estimands
Draw event probabilities
Get parameter matrix
Look up query types
helper to get type distributions
Helpers for inspecting causal models
Interpret or find position in nodal type
Returns a list with the nodes that are not directly pointing into a no...
Helper to run a causal statement specifying a DAG into a data.frame
...
Generate full dataset
Make a model
make_par_values_stops
make_par_values
function to make a parameters_df from nodal types
Make a prior distribution from priors
Observe data, given a strategy
Setting parameters
Helper to turn parents_list into a list of data_realizations column po...
Produces the possible permutations of a set of nodes
Plots a DAG in ggplot style using a causal model input
Prepare data for 'stan'
Print a short summary for a causal model
Print a tightened summary of model queries
Setting priors
Calculate query distribution
Query helpers
Generate data frame for batches of causal queries
Helper to turn query into a data expression
Realise outcomes
Reveal outcomes
Set confound
Set parameter matrix
Add prior distribution draws
Restrict a model
Summarizing causal models
Summarizing model queries
Fit causal model using 'stan'
Users can declare causal models over binary nodes, update beliefs about causal types given data, and calculate arbitrary queries. Updating is implemented in 'stan'. See Humphreys and Jacobs, 2023, Integrated Inferences (<DOI: 10.1017/9781316718636>) and Pearl, 2009 Causality (<DOI:10.1017/CBO9780511803161>).
Useful links