[R] Running Shell Script with R
johnandrewpura at gmail.com
Mon Nov 28 17:10:01 CET 2011
I'm having some trouble getting my shell script to work. I've checked out the
Intro to R Manual and a host of other websites, but I still can't get the
script to work when I submit the job to the cluster.
Here is my main R code:
## Load Time Data
Args <- commandArgs(trailingOnly = TRUE);
timeDat <- read.flowSet(files=NULL, path=Args);
save(timeDat,file = Args);
Here is my shell script file
#$ -q all.q
R --slave --vanilla --file="/home/jpura/Desktop/FDA_Trial_Data/testscript.R"
It runs just fine (i.e. I get the right output file, which is
testscript.RData) when I type the lines in the shell script file directly
into the command prompt. However, when I try to submit the file using:
qsub "path/to/testscript.sh", I don't get the desired output file.
Any insights to this is be greatly appreciated.
View this message in context: http://r.789695.n4.nabble.com/Running-Shell-Script-with-R-tp4115734p4115734.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help