get_all_data_types {CausalQueries} | R Documentation |
Get all data types
Description
Creates dataframe with all data types (including NA types) that are possible from a model.
Usage
get_all_data_types(
model,
complete_data = FALSE,
possible_data = FALSE,
given = NULL
)
Arguments
model |
A |
complete_data |
Logical. If 'TRUE' returns only complete data types (no NAs). Defaults to 'FALSE'. |
possible_data |
Logical. If 'TRUE' returns only complete data types (no NAs) that are *possible* given model restrictions. Note that in principle an intervention could make observationally impossible data types arise. Defaults to 'FALSE'. |
given |
A character. A quoted statement that evaluates to logical. Data conditional on specific values. |
Value
A data.frame
with all data types (including NA types)
that are possible from a model.
Examples
make_model('X -> Y') |> get_all_data_types()
model <- make_model('X -> Y') %>%
set_restrictions(labels = list(Y = '00'), keep = TRUE)
get_all_data_types(model)
get_all_data_types(model, complete_data = TRUE)
get_all_data_types(model, possible_data = TRUE)
get_all_data_types(model, given = 'X==1')
get_all_data_types(model, given = 'X==1 & Y==1')
[Package CausalQueries version 1.1.1 Index]