I am trying to onboard a team of 200 people onto a tool that uses R to move data from Excel to a database. I walk the team through the following steps:
- Download R from the closest cran mirror and install in program files
- Download R studio and install RStudio (wherever it defaults to)
- Open RStudio and run the following code:
List.of.Packages = c("car", ### <-- Regression analyses
"corrplot", ### <-- Plots correlation matrices
"plyr", ### <-- Basic data cleaning
"dplyr", ### <-- Basic data cleaning for dataframes
"filesstrings", ### <-- Moves/manipulates files
"httr", ### <-- Facilitates HTTP calls
"jsonlite", ### <-- Manipulate json data
"lubridate", ### <-- Allows for easier manipulation of dates
"tidyr", ### <-- Data cleaning methods
"zoo", ### <-- Aggregate functions
"methods", ### <-- Runs R through terminal
"RDCOMClient", ### <-- Interact with Outlook from R
"stringr", ### <-- Easier manipulation of Strings
"openxlsx", ### <-- Read/write from/to Excel
"XML", ### <-- Manipulates XML data
"rjson", ### <-- Manipulation of json data
"purrr", ### <-- Enhanced exploration of functions and vectors
"listviewer", ### <-- Enhanced exploration of lists
"xlsx", ### <-- Enhanced exploration of lists
"rvest") ### <-- "Harvest" (Webscraping and API utilities)
New.Packages = List.of.Packages[!(List.of.Packages %in% installed.packages()[,"Package"])]
if(length(New.Packages)) install.packages(New.Packages, repos = "http://cran.rstudio.com/")
At this point, some users get Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding...
but others do not.
I understand and have seen all the posts related to how to install Rtools. But what I'm asking here is... how can this not be consistent? Why would the same installation process and the same code require some people to take an extra step while others did not have to? Is there some configuration part of the install that also installs Rtools that some people might not be including? How can I make this onboarding process repeatable?