我正在编写用于分析使用system2函数的数据的脚本。我希望我的职能适当。
我的函数返回了问题:
Class 'try-error' atomic [1:1] Error in system2(file.path(script.dir, "script1.sh"), c(matlab.dir, :
error in running command
..- attr(*, "condition")=List of 2
.. ..- attr(*, "class")= chr [1:3] "simpleError" "error" "condition"
NULL
Error occurred: Error in system2(file.path(script.dir, "script1.sh"), c(matlab.dir, :
error in running command
runPicnic <- function(sample.name, sample.type, sample.sex, sample.chip, script.dir, matlab.dir) {
pre.res = system2(file.path(script.dir, 'script1.sh'), c(matlab.dir, sample.name, 'outdir', sample.type, sample.sex, sample.chip), stdout=TRUE, stderr=TRUE)
post.res = system2(file.path(script.dir, 'script2.sh'), c(matlab.dir, sample.name, 'outdir'), stdout=TRUE, stderr=TRUE)
return( list(pre.res, post.res) )
}
我正在使用此代码将作业发送到群集上的队列。