Closed chendaniely closed 9 years ago
I've been using this option, 1 caveat, the root directory only takes effect for subsequent chunks. Thus any source commands in the same chunk will not have the root directory set.
This might actually be fixed. If you invoke RStudio directly from the directory (apparently, as you should be), the relative directory issue all works the way you expect.
You might still have to do this if you use the Projects feature, but I haven't tested that/use those anymore.
@chendaniely, is there any action that needs to be taken on this issue? If yes, please detail. If no, please close.
No action needed. Closing this issue.
For the instructors teaching knitr, please take a look at this issue: https://github.com/yihui/knitr/issues/277
essentially knitr doesn't follow the same working directory as the rscript/r session. you actually need a code chunk to set the root directory
opts_knit$set(root.dir = 'c:/Users/kwilliams/git/ProjectX')
There's been discussion on working directories and how/where to invoke R, etc in #639 and #658
Just figured this out, thought i'd share...