R/summarize_control_quality.R
summarize_control_quality.Rd
summarize_control_quality()
allows you to summarize how well studies
control for variables within one or more domains, and how well those domains
are controlled for overall. Each logical statement is a domain and can be
named.
summarize_control_quality(.df, ..., domains = TRUE)
A data frame, usually the result of metaconfoundr()
Boolean arguments to declare adequate control logic
Logical. Include the domains in the output? If FALSE
, only
returns overall control quality.
A tibble
summary_df <- summarize_control_quality(
metaconfoundr(ipi),
Sociodemographics = `Maternal age` & `Race/ethnicity` & `Marital status`,
Socioeconomics = `SES category` | Insurance & Education,
"Reproductive Hx" = `Prior pregnancy outcome`
)
summary_df
#> # A tibble: 44 × 4
#> study variable control_quality construct
#> <chr> <fct> <ord> <fct>
#> 1 Zhu_2001a overall some concerns overall
#> 2 Zhu_2001a Sociodemographics adequate domains
#> 3 Zhu_2001a Socioeconomics inadequate domains
#> 4 Zhu_2001a Reproductive Hx adequate domains
#> 5 Zhu_2001b overall some concerns overall
#> 6 Zhu_2001b Sociodemographics adequate domains
#> 7 Zhu_2001b Socioeconomics inadequate domains
#> 8 Zhu_2001b Reproductive Hx adequate domains
#> 9 Zhu_1999 overall some concerns overall
#> 10 Zhu_1999 Sociodemographics adequate domains
#> # … with 34 more rows
summary_df %>%
mc_trafficlight() +
theme_mc() +
facet_constructs() +
geom_cochrane() +
scale_fill_cochrane()