When working locally, I use the following to render rmarkdown documents:
rmarkdown::render(input = rmd.temp , output_dir = out.dir, output_file = out.name)
This gets my doc template rmd.temp, then displays the document out.dirand names the file out.name.
I am trying to replicate on an RStudio server. When out.diris a local directory, the code works fine. However, when it out.diris a mapped directory to an external drive, I get the following error:
Error in replayPlot(x) :
could not open file'/...path..../figure-html/unnamed-chunk-2-1.png'
The mapped drive link works because I can use:
dir.create(out.dir)
and see the new folder. Any ideas why the rendering is stuck?
Update
This is probably just a resolution problem because I cannot write a csv file:
df <- data.frame(a=1:10)
setwd(out.dir)
write.csv(df, file = "df.csv")
Error in file(file, ifelse(append, "a", "w")) :
cannot open the connection
RStudio Ubuntu. , RStudio.