Command to get the working directory in R is code example Example: r set working directory setwd("/Users/SampleUser/Desktop/R")