B Appendix B: Reporting on Git and Session Info in R
This code lists the versions of R and all the R packages I’m using, tells me which computer and operating system processed these files, and connects this output to its git commit.
## [1] "mac-gonzo05.local"
## [1] "commit 5a7aba660d216e83adf3fa9f97f5eeb2cddb43bb"
## [2] "Author: Richard D Gonzalez <gonzo@umich.edu>"
## [3] "Date: Tue Dec 15 20:32:35 2020 -0500"
## R version 4.0.3 (2020-10-10)
## Platform: x86_64-apple-darwin17.0 (64-bit)
## Running under: macOS High Sierra 10.13.6
##
## Matrix products: default
## BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
## LAPACK: /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libRlapack.dylib
##
## attached base packages:
## [1] grid splines stats graphics grDevices
## [6] utils datasets methods base
##
## other attached packages:
## [1] MplusAutomation_0.8 nlsr_2019.9.7
## [3] BayesFactor_0.9.12-4.2 coda_0.19-4
## [5] xml2_1.3.2 pacman_0.5.1
## [7] gdtools_0.2.3 tsfeaturex_0.4.1
## [9] GauPro_0.2.2.9000 ggiraph_0.7.9
## [11] urbnmapr_0.0.0.9002 fiftystater_1.0.1
## [13] nnet_7.3-15 NeuralNetTools_1.5.2
## [15] tibbletime_0.1.6 tidybayes_2.3.1
## [17] bayesplot_1.8.0 brms_2.15.0
## [19] Rcpp_1.0.6 ggfortify_0.4.11
## [21] hts_6.0.1 forecast_8.13
## [23] investr_1.4.0 RColorBrewer_1.1-2
## [25] ggforce_0.3.3 pracma_2.3.3
## [27] pander_0.6.3 nlrx_0.4.2
## [29] gamm4_0.2-6 mgcv_1.8-34
## [31] texreg_1.37.5 stargazer_5.2.2
## [33] rnn_1.4.0 readxl_1.3.1
## [35] Hmisc_4.5-0 Formula_1.2-4
## [37] survival_3.2-10 lattice_0.20-41
## [39] merTools_0.5.2 arm_1.11-2
## [41] MASS_7.3-53.1 nlme_3.1-152
## [43] lme4_1.1-23 Matrix_1.3-2
## [45] sjlabelled_1.1.7 sjmisc_2.8.6
## [47] sjPlot_2.8.7 ggrepel_0.9.1
## [49] viridis_0.5.1 viridisLite_0.3.0
## [51] ggthemes_4.2.4 maps_3.3.0
## [53] scales_1.1.1 ggeffects_1.0.1
## [55] gganimate_1.0.7 tidycensus_0.11.4
## [57] magrittr_2.0.1 rvest_1.0.0
## [59] forcats_0.5.0 stringr_1.4.0
## [61] dplyr_1.0.5 purrr_0.3.4
## [63] tidyr_1.1.3 tibble_3.0.4
## [65] ggplot2_3.3.3 tidyverse_1.3.0
## [67] readr_1.4.0 bookdown_0.21
## [69] knitr_1.30
##
## loaded via a namespace (and not attached):
## [1] class_7.3-18 ps_1.6.0
## [3] foreach_1.5.1 projpred_2.0.2
## [5] lmtest_0.9-38 rprojroot_2.0.2
## [7] crayon_1.4.1 V8_3.4.0
## [9] backports_1.2.1 reprex_1.0.0
## [11] colourpicker_1.1.0 rlang_0.4.10
## [13] performance_0.7.0 SparseM_1.78
## [15] nloptr_1.2.2.2 callr_3.5.1
## [17] proto_1.0.0 sigmoid_0.3.0
## [19] glue_1.4.2 loo_2.4.1
## [21] rstan_2.21.2 parallel_4.0.3
## [23] processx_3.4.5 classInt_0.4-3
## [25] haven_2.3.1 tidyselect_1.1.0
## [27] usethis_2.0.1 zoo_1.8-8
## [29] sf_0.9-7 distributional_0.2.2
## [31] xtable_1.8-4 MatrixModels_0.4-1
## [33] evaluate_0.14 quantmod_0.4.17
## [35] cli_2.3.1 rstudioapi_0.13
## [37] miniUI_0.1.1.1 gifski_0.8.7.1
## [39] sp_1.4-4 bslib_0.2.4
## [41] rpart_4.1-15 svUnit_1.0.3
## [43] shinystan_2.5.0 shiny_1.6.0
## [45] xfun_0.22 parameters_0.12.0
## [47] inline_0.3.17 pkgbuild_1.2.0
## [49] cluster_2.1.1 bridgesampling_1.0-0
## [51] urca_1.3-0 Brobdingnag_1.2-6
## [53] threejs_0.3.3 png_0.1-7
## [55] withr_2.4.1 plyr_1.8.6
## [57] cellranger_1.1.0 e1071_1.7-4
## [59] pillar_1.5.1 RcppParallel_5.0.3
## [61] multcomp_1.4-14 fs_1.5.0
## [63] TTR_0.24.2 xts_0.12.1
## [65] vctrs_0.3.6 ellipsis_0.3.1
## [67] generics_0.0.2 dygraphs_1.1.1.6
## [69] gsubfn_0.7 devtools_2.3.2
## [71] rgdal_1.5-23 tools_4.0.3
## [73] foreign_0.8-81 entropy_1.2.1
## [75] munsell_0.5.0 tweenr_1.0.1
## [77] emmeans_1.5.4 fastmap_1.1.0
## [79] compiler_4.0.3 pkgload_1.1.0
## [81] abind_1.4-5 httpuv_1.5.5
## [83] tigris_1.0 sessioninfo_1.1.1
## [85] gridExtra_2.3 arrayhelpers_1.1-0
## [87] utf8_1.1.4 later_1.1.0.1
## [89] jsonlite_1.7.2 pbapply_1.4-3
## [91] estimability_1.3 tseries_0.10-47
## [93] promises_1.2.0.1 latticeExtra_0.6-29
## [95] effectsize_0.4.4 checkmate_2.0.0
## [97] rmarkdown_2.7 sandwich_3.0-0
## [99] blme_1.0-5 statmod_1.4.34
## [101] selectr_0.4-2 igraph_1.2.6
## [103] rsconnect_0.8.16 yaml_2.2.1
## [105] systemfonts_1.0.1 htmltools_0.5.1.1
## [107] rstantools_2.1.1 memoise_1.1.0
## [109] quadprog_1.5-8 digest_0.6.27
## [111] assertthat_0.2.1 mime_0.10
## [113] rappdirs_0.3.3 bayestestR_0.8.2
## [115] units_0.7-0 debugme_1.1.0
## [117] mapproj_1.2.7 remotes_2.2.0
## [119] data.table_1.14.0 fracdiff_1.5-1
## [121] shinythemes_1.2.0 labeling_0.4.2
## [123] broom_0.7.5 hms_0.5.3
## [125] modelr_0.1.8 colorspace_2.0-0
## [127] base64enc_0.1-3 mnormt_2.0.2
## [129] tmvnsim_1.0-2 broom.mixed_0.2.6
## [131] sass_0.3.1 mvtnorm_1.1-1
## [133] matrixcalc_1.0-3 fansi_0.4.1
## [135] lbfgs_1.2.1 R6_2.5.0
## [137] ggridges_0.5.3 lifecycle_1.0.0
## [139] formatR_1.7 StanHeaders_2.21.0-7
## [141] curl_4.3 minqa_1.2.4
## [143] testthat_3.0.2 jquerylib_0.1.3
## [145] snakecase_0.11.0 desc_1.2.0
## [147] TH.data_1.0-10 iterators_1.0.13
## [149] TMB_1.7.19 htmlwidgets_1.5.3
## [151] polyclip_1.10-0 markdown_1.1
## [153] crosstalk_1.1.0.1 insight_0.13.1
## [155] htmlTable_2.1.0 codetools_0.2-18
## [157] matrixStats_0.57.0 lubridate_1.7.9
## [159] gtools_3.8.2 prettyunits_1.1.1
## [161] psych_2.0.12 dbplyr_2.1.0
## [163] ggdist_2.4.0 gtable_0.3.0
## [165] DBI_1.1.0 stats4_4.0.3
## [167] httr_1.4.2 highr_0.8
## [169] KernSmooth_2.23-18 stringi_1.5.3
## [171] progress_1.2.2 reshape2_1.4.4
## [173] farver_2.0.3 uuid_0.1-4
## [175] timeDate_3043.102 DT_0.17
## [177] boot_1.3-27 shinyjs_2.0.0
## [179] sjstats_0.18.1 jpeg_0.1-8.1
## [181] pkgconfig_2.0.3 maptools_1.0-2
## [183] Langevin_1.2.1
It is good to save this information to a separate file so that it can be added to the git repo and current versions of packages are listed.
There are more systematic approaches to creating self-contained environments with the package renv or solutions outside R such as docker containers.