MARGinal Observational Treatment-effects.1
Causal inference requires balance across the treatments to be compared. In observational studies, such balance is not guaranteed; quantifying causality therefore requires careful, multi-step workflows.
The goal of margot
is to enhance the accessibility of these workflows
for causal inference. Its primary audience includes psychological
scientists, although it may benefit other social scientists.
The package offers functions for:
- evaluating causal assumptions
- modelling time-series data
- reporting results
- performing sensitivity analyses
margot
focuses on streamlining the estimation of (Marginal) Average
Treatment Effects, but it also supports workflows for Conditional
Average Treatment Effects and exploring Heterogeneous Treatment Effects,
as well as Modified Treatment Policies.
You can install the development version of margot
like so:
if (!require(devtools, quietly = TRUE)) {
install.packages("devtools")
library(devtools)
}
devtools::install_github("go-bayes/margot")
library("margot")
# create transition table to evaluate the positivity assumption
transition_matrix <- create_transition_matrix(df_nz, "religion_believe_god", "id")
# create table and table explanation
table_change_belief <- transition_table(transition_matrix)
table_change_belief
Go to:https://github.com/go-bayes/margot
The code in this package is licensed under the Creative Commons Attribution 4.0 International (CC BY 4.0) license. You are free to share and adapt the code, even for commercial purposes, provided that you attribute the original author(s) appropriately. For more information, see CC BY 4.0.
The margot
package is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the Disclaimer
of Warranties and Limitation of Liability section in the licensing
information for more details.
If you use the margot
package in your research, you may cite it as
follows:
bibentry(
bibtype = "Manual",
title = "margot: MARGinal Observational Treatment-effects",
author = person("Joseph A", "Bulbulia"),
year = "2024",
note = "R package version 0.3.0.5, Functions to obtain MARGinal Observational Treatment-effects from observational data.",
url = "https://go-bayes.github.io/margot/",
doi = "10.5281/zenodo.10907724"
)
Footnotes
-
The logo is a Single World Intervention Template (SWIT). We use a SWIT to generate Single World Intervention Graphs (SWIGs) – causal diagrams for which identification assumptions can be read separately for each treatment (regime) to be compared. The name
margot
reflects the contents and aims of this package; it is also the name of my daughter, Margot. ↩