knitr::opts_chunk$set( message = FALSE, echo = FALSE)
# find the combinations tar_load(oti_results) library(adpain) comp <- oti_results %>% filter(intervention == "duloxetine", model_type == "smd" ) %>% mutate(dir = map_chr(outcome, outcome_dir)) %>% count(outcome, dir) %>% group_by(dir) %>% slice(1) %>% select(-n) %>% ungroup()
pick a subgroup to analyse and compare results
tar_load(oti_pw) lower_example <- comp %>% filter(dir == "lower") %>% left_join(oti_pw) %>% filter(intervention == "duloxetine", timepoint == "post_int")
lower_example$pw_rma[[1]]$rma %>% forest() lower_example$pw_rma[[1]]$rma
lower_example %>% select(contains("nma"))
lower_md <- escalc(m1i = mean, m2i = mean_control, sd1i = sd, sd2i = sd_control, n1i = n, n2i = n_control, data = lower_example$pw_dat, measure = "MD", slab = study) %>% rma(measure = "MD", data = ., yi = yi, vi = vi, slab = study) lower_md %>% forest() lower_md
higher_example <- comp %>% filter(dir == "higher") %>% left_join(oti_pw) %>% filter(intervention == "duloxetine", timepoint == "post_int")
higher_example$pw_rma[[1]]$rma %>% forest() higher_example$pw_rma[[1]]$rma
higher_example %>% select(contains("nma"))
higher_md <- escalc(m1i = mean, m2i = mean_control, sd1i = sd, sd2i = sd_control, n1i = n, n2i = n_control, data = higher_example$pw_dat, measure = "MD", slab = study) %>% rma(measure = "MD", data = ., yi = yi, vi = vi, slab = study) higher_md %>% forest()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.