A convenience function that loops through and reads in code in .R files stored in a folder located in the current working directory.

source_R_scripts(files_to_include = NULL, path = "R")

Arguments

files_to_include

A vector of either...

  • Numeric indices denoting which files to include;

  • A character string matching the initial set of letters across all relevant files (e.g., if all scripts of interest start with the letter 'S');

  • A character vector with the full file names for the files to include.

path

The folder name with the scripts to source.

Author

Kevin Potter