Data and analysis pertaining to my progress, or lack thereof, over time in terms of training, diet, and body composition.
This repository contains the necessary files and code to reproduce the analyses and figures.
To reproduce the analyses, you will need to have R (https://cran.r-project.org/) and RStudio (https://www.rstudio.com/products/rstudio/download/#download) installed on your computer.
To help with reproducibility, this project uses the renv R package (see https://rstudio.github.io/renv/articles/renv.html). With renv, the state of this R project can be easily loaded as renv keeps track of the required R packages (including version), and (if known) the external source from which packages were retrieved (e.g., CRAN, Github). With renv, packages are installed to a project specific library rather than your user or system library. The renv package must be installed on your machine before being able to benefit from its features. The package can be installed using the following command:
install.packages("renv")Once you have renv installed, you can get a copy of this repository on your machine by clicking the green Code button then choose Download zip. Save to your machine and extract. After extraction, double click the blackpill_progress.Rproj file in the root directory. This will automatically open RStudio. This will ensure all paths work on your system as the working directory will be set to the location of the .Rproj file. Upon opening, RStudio will recognize the renv files and you will be informed that the project library is out of sync with the lockfile. At shown in the console pane of RStudio, running renv::restore() will install the packages recorded in the lockfile. This could take some time depending on your machine and internet connection.
This project also uses a function based analysis pipeline using
targets. Instead of script based pipelines the targets package makes use of functions applied to targets specified within the pipeline. The targets can be viewed in the _targets.R file, and any user defined functions are available in R/functions.r.
Useful console functions:
tar_edit()opens the make filetar_make()to run targetstar_visnetwork()to view pipeline
The grateful package was used to create citations to all software and packages used in the analysis. The grateful report can be viewed by downloading the grateful-report.pdf file.
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

