This document contains the R package information for the analyses performed for the chronic conditions study.

study collate date language system tz ui version
meta en_US.UTF-8 2020-03-17 (EN) x86_64, darwin15.6.0 America/Los_Angeles X11 R version 3.6.2 (2019-12-12)
BASEII German_Germany.1252 2018-02-03 (EN) x86_64, mingw32 Europe/Berlin RStudio (1.0.153) R version 3.4.3 (2017-11-30)
EAS English_United States.1252 2018-01-15 (EN) x86_64, mingw32 America/Chicago RStudio (1.1.383) R version 3.4.3 (2017-11-30)
ELSA English_Canada.1252 2018-01-31 (EN) x86_64, mingw32 America/Los_Angeles RStudio (1.1.383) R version 3.4.3 (2017-11-30)
HRS en_US.UTF-8 2018-02-08 (EN) x86_64, darwin15.6.0 RStudio (1.1.383) R version 3.4.2 (2017-09-28)
ILSE English_United States.1252 2018-02-01 (EN) x86_64, mingw32 Europe/Berlin RStudio (1.1.419) R version 3.4.3 (2017-11-30)
LBC English_United Kingdom.1252 2018-10-19 (EN) x86_64, mingw32 Europe/London RStudio (1.1.456) R version 3.5.1 (2018-07-02)
LBLS en_US.UTF-8 2018-02-06 (EN) x86_64, darwin13.4.0 America/Los_Angeles RStudio (1.0.143) R version 3.3.2 (2016-10-31)
MAP English_United States.1252 2018-02-07 (EN) x86_64, mingw32 America/Chicago RStudio (1.1.383) R version 3.4.3 (2017-11-30)
MAS English_Australia.1252 2018-03-04 (EN) x86_64, mingw32 Australia/Sydney RStudio (1.1.383) R version 3.4.3 (2017-11-30)
MIDUS en_US.UTF-8 2018-04-27 (EN) x86_64, darwin15.6.0 America/Chicago RStudio (1.1.442) R version 3.4.4 (2018-03-15)
NAS en_US.UTF-8 2018-01-26 (EN) x86_64, darwin15.6.0 America/Chicago RStudio (1.1.383) R version 3.4.3 (2017-11-30)
OATS English_Australia.1252 2018-02-01 (EN) x86_64, mingw32 America/New_York RStudio (1.1.383) R version 3.4.3 (2017-11-30)
ROS English_United States.1252 2018-02-02 (EN) x86_64, mingw32 America/Chicago RStudio (1.1.383) R version 3.4.3 (2017-11-30)
SLS German_Germany.1252 2018-07-12 (EN) x86_64, mingw32 Europe/Berlin RStudio (1.0.153) R version 3.4.3 (2017-11-30)
WLS English_Canada.1252 2018-02-03 (EN) x86_64, mingw32 America/Los_Angeles RStudio (1.0.153) R version 3.4.3 (2017-11-30)
## Joining, by = c("package", "*", "version", "study")
## Note: Using an external vector in selections is ambiguous.
## ℹ Use `all_of(study.names)` instead of `study.names` to silence this message.
## ℹ See <https://tidyselect.r-lib.org/reference/faq-external-vector.html>.
## This message is displayed once per session.
package meta BASEII EAS ELSA HRS ILSE LBC LBLS MAP MAS MIDUS NAS OATS ROS SLS WLS
apaTables 1.5.1 1.5.1 1.5.1 1.5.1 1.5.1 2.0.5 1.5.1 1.5.1 1.5.1 2.0.2 1.5.1 1.5.1 1.5.1 1.5.1 1.5.1
arm 1.10-1
base 3.4.3 3.4.3 3.4.3 3.4.2 3.4.3 3.5.1 3.3.2 3.4.3 3.4.3 3.4.4 3.4.3 3.4.3 3.4.3 3.4.3 3.4.3
bindrcpp 0.2 0.2 0.2 0.2 0.2 0.2.2 0.2 0.2 0.2 0.2.2 0.2 0.2 0.2 0.2 0.2
data.table 1.10.4-3
datasets 3.4.3 3.4.3 3.4.3 3.4.2 3.4.3 3.5.1 3.3.2 3.4.3 3.4.3 3.4.4 3.4.3 3.4.3 3.4.3 3.4.3 3.4.3
devtools 2.2.1 1.13.4 1.13.4 1.13.4 1.13.4 1.13.4 1.13.6 1.13.4 1.13.4 1.13.4 1.13.5 1.13.4 1.13.4 1.13.4 1.13.4 1.13.4
dplyr 0.8.4 0.7.4 0.7.4 0.7.4 0.7.4 0.7.4 0.7.6 0.7.4 0.7.4 0.7.4 0.7.4 0.7.4 0.7.4 0.7.4 0.7.4 0.7.4
forcats 0.4.0 0.2.0 0.2.0 0.2.0 0.2.0 0.2.0 0.3.0 0.2.0 0.2.0 0.2.0 0.3.0 0.2.0 0.2.0 0.2.0 0.2.0 0.2.0
foreign 0.8-69 0.8-69 0.8-69 0.8-71 0.8-69 0.8-69 0.8-69 0.8-70 0.8-69 0.8-69 0.8-69 0.8-69 0.8-69
ggplot2 3.2.1 2.2.1 2.2.1 2.2.1 2.2.1 2.2.1 3.0.0 2.2.1 2.2.1 2.2.1 2.2.1 2.2.1 2.2.1 2.2.1 2.2.1 2.2.1
GPArotation 2014.11-1 2014.11-1 2014.11-1 2014.11-1 2014.11-1 2014.11-1 2014.11-1 2014.11-1 2014.11-1 2014.11-1 2014.11-1 2014.11-1 2014.11-1 2014.11-1 2014.11-1
graphics 3.4.3 3.4.3 3.4.3 3.4.2 3.4.3 3.5.1 3.3.2 3.4.3 3.4.3 3.4.4 3.4.3 3.4.3 3.4.3 3.4.3 3.4.3
grDevices 3.4.3 3.4.3 3.4.3 3.4.2 3.4.3 3.5.1 3.3.2 3.4.3 3.4.3 3.4.4 3.4.3 3.4.3 3.4.3 3.4.3 3.4.3
haven 1.1.0
here 0.1
kableExtra 1.1.0
knitr 1.28
lme4 1.1-21
MASS 7.3-51.5
Matrix 1.2-18
merTools 0.5.0
metafor 2.1-0
methods 3.4.3 3.4.3 3.4.3 3.4.2 3.4.3 3.5.1 3.3.2 3.4.3 3.4.3 3.4.4 3.4.3 3.4.3 3.4.3 3.4.3 3.4.3
papaja 0.1.0.9842
psych 1.9.12 1.7.8 1.7.8 1.7.8 1.7.8 1.7.8 1.8.4 1.7.8 1.7.8 1.7.8 1.8.3.3 1.7.8 1.7.8 1.7.8 1.7.8 1.7.8
purrr 0.3.3 0.2.4 0.2.4 0.2.4 0.2.4 0.2.4 0.2.5 0.2.4 0.2.4 0.2.4 0.2.4 0.2.4 0.2.4 0.2.4 0.2.4 0.2.4
readr 1.3.1 1.1.1 1.1.1 1.1.1 1.1.1 1.1.1 1.1.1 1.1.1 1.1.1 1.1.1 1.1.1 1.1.1 1.1.1 1.1.1 1.1.1 1.1.1
readstata13 0.9.0
sas7bdat 0.5
sjPlot 2.4.0 2.4.0 2.4.0 2.4.0 2.4.0 2.6.0 2.4.0 2.4.0 2.4.0 2.4.1 2.4.0 2.4.0 2.4.0 2.4.0 2.4.0
stargazer 5.2.1 5.2.1
stats 3.4.3 3.4.3 3.4.3 3.4.2 3.4.3 3.5.1 3.3.2 3.4.3 3.4.3 3.4.4 3.4.3 3.4.3 3.4.3 3.4.3 3.4.3
stringr 1.4.0 1.2.0 1.2.0 1.2.0 1.2.0 1.2.0 1.3.1 1.2.0 1.2.0 1.2.0 1.3.0 1.2.0 1.2.0 1.2.0 1.2.0 1.2.0
survival 2.41-3 2.41-3
tibble 2.1.3 1.4.1 1.4.1 1.4.1 1.3.4 1.4.2 1.4.2 1.4.1 1.4.2 1.4.1 1.4.2 1.3.4 1.4.1 1.4.2 1.4.1 1.4.1
tidyr 1.0.2 0.7.2 0.7.2 0.7.2 0.7.2 0.8.0 0.8.1 0.7.2 0.8.0 0.7.2 0.8.0 0.7.2 0.7.2 0.8.0 0.7.2 0.7.2
tidyverse 1.3.0 1.2.1 1.2.1 1.2.1 1.2.1 1.2.1 1.2.1 1.2.1 1.2.1 1.2.1 1.2.1 1.2.1 1.2.1 1.2.1 1.2.1 1.2.1
usethis 1.5.1
utils 3.4.3 3.4.3 3.4.3 3.4.2 3.4.3 3.5.1 3.3.2 3.4.3 3.4.3 3.4.4 3.4.3 3.4.3 3.4.3 3.4.3 3.4.3

Code

library(devtools)
library(knitr)
library(kableExtra)
library(lme4)
library(merTools)
library(tidyverse)
library(metafor)
library(papaja)
library(here)
study.names = c("BASEII", "EAS", "ELSA", "HRS", "ILSE", "LBC",
                "LBLS","MAP", "MAS", "MIDUS",
                "NAS", "OATS", "ROS", "SLS", "WLS")

load(here("chronic/created data/BASEII_cc_output_nosrh.Rdata"))
load(here("chronic/created data/EAS_cc_output_nosrh.Rdata"))
load(here("chronic/created data/ELSA_cc_output.Rdata"))
load(here("chronic/created data/HRS_cc_output.Rdata"))
load(here("chronic/created data/ILSE_cc_output_nosrh.Rdata"))
load(here("chronic/created data/LBC_cc_output.Rdata"))
load(here("chronic/created data/LBLS_cc_output.Rdata"))
load(here("chronic/created data/MAP_cc_output.Rdata"))
load(here("chronic/created data/MAS_cc_output_nosrh.Rdata"))
load(here("chronic/created data/MIDUS_cc_output_nosrh.Rdata"))
load(here("chronic/created data/nas_cc_output.Rdata"))
load(here("chronic/created data/OATS_cc_output_nosrh.Rdata"))
load(here("chronic/created data/ROS_cc_output.Rdata"))
load(here("chronic/created data/SLS_cc_output.Rdata"))
load(here("chronic/created data/WLS_cc_output.Rdata"))

NAS_cc_output = nas_cc_output
EAS_cc_output= eas_cc_output
rm(nas_cc_output)
rm(eas_cc_output)
s <- session_info()
meta_cc_output = list(session_info = s)
meta_cc_output$session_info$platform$os = NULL
meta_cc_output$session_info$platform$ctype = NULL
platform_info = lapply(c("meta", study.names), function(x) get(paste0(x, "_cc_output")))
names(platform_info) = c("meta", study.names)

platform_info %>%
  map("session_info") %>%
  map("platform") %>%
  map_df(~unlist(.)) %>%
  mutate(var = names(meta_cc_output$session_info$platform)) %>%
  gather("study", "value", -var) %>%
  spread("var", "value") %>%
  mutate(study = factor(study, levels = c("meta", study.names))) %>%
  arrange(study) %>%
  kable(., booktabs = TRUE) %>%
  kable_styling()
package_info = lapply(c(study.names), function(x) get(paste0(x, "_cc_output")))
names(package_info) = c(study.names)

meta_packages = meta_cc_output$session_info$packages
meta_packages = meta_packages %>%
  mutate(study = "meta") %>%
  mutate(version = loadedversion,
         `*` = attached) %>%
  dplyr::select(study, package, version, `*`) %>%
  mutate(`*` = ifelse(`*`, "*", ""))

package_info %>%
  map("session_info") %>%
  map("packages") %>%
  map2_df(., c(study.names), ~ mutate(.x, study = .y)) %>%
  full_join(meta_packages) %>%
  filter(`*` == "*") %>%
  dplyr::select(study, package, version) %>%
  spread(study, version) %>%
  dplyr::select(c(package, "meta", study.names)) %>%
  kable(., booktabs = TRUE) %>%
  kable_styling(font_size = 9)