On Tue, Oct 12, 2010 at 10:43 AM, Freddy <freddy.debree@wur.nl> wrote:
Hi Peter,
Running R from xml is not so straight forward to me. Is the interpreter "bash" or is it "R"? If "bash" then it should be running "R --vanilla --slave input < Rscript > output" if "R" then it should be running ? smthg like "source(Rscript)"
Hope you can help...
Freddy
Consider a simple R script, hello_world.R like this: print('Hello world'); print(commandArgs()); Then in Galaxy I think you'd need the default interpreter ("bash") and the command to be: R --vanilla --file=hello_world.R --args "Args go here" I'm assuming your script will write useful output to a file, and stdout can be discarded. However, what I originally had in mind was setting the hash bang and executable bit with chmod so that you can do this at the command line: ./hello_world.R "Args go here" Once that works, calling it from Galaxy should be trivial. I think one way to do this is with the little r package: http://code.google.com/p/littler/ Peter