[R] sink() output to another directory

Rich Shepard r@hep@rd @end|ng |rom @pp|-eco@y@@com
Fri Sep 14 01:28:09 CEST 2018


On Thu, 13 Sep 2018, Peter Langfelder wrote:

> Remove the / from the print command, it does not belong there.

Peter,

   So the print() function cannot accept a relative path to a different
directory for its output? This does seem to be the case:

source('rainfall-dubois-crk-all.r')
Error in source("rainfall-dubois-crk-all.r") :
   rainfall-dubois-crk-all.r:25:7: unexpected '/'
24: sink('stat-summaries/estacada-wnw-precip.txt')
25: print(/
           ^

   Then I'll print to the cwd and move the files manually afterwards.

Thanks,

Rich




More information about the R-help mailing list