4

Trying to run a function where I set the directory to wherever is specified in the arguments.

However every time I do, I get the error message:

"Error in setwd(dir): cannot change working directory"

This happens even if I've already changed the wd manually in the console and I have absolutely no clue why it's being so annoying.

Thanks in advance!

Rose Savage
  • 61
  • 1
  • 4
  • 2
    In most situations, "Error in setwd(dir): cannot change working directory" appears when the directory set doesn't exist at all. Perhaps, you can check the working directory by running getwd() function to verify the location first. Also, check if you used / rather than \ to set the location. – Sunny Sep 20 '17 at 09:10

0 Answers0