I have encountered the following error while running an application:
Caused by: java.io.IOException: Cannot run program "R": java.io.IOException: error=2, No such file or directory
The above came after the following invocation, from the log file:
Tue Oct 19 22:59:16 GMT 2010 Calling R CMD BATCH --profileFiles=/home2/jason/birdsuite/TEST_OUT/test.probeset_summary --outDir=/home2/jason/birdsuite/TEST_OUT --verbose=T --no-readline --priorsFile=/home2/jason/birdsuite/METADATADIR/GenomeWideSNP_6.canary_priors --offsetFile=/home2/jason/birdsuite/METADATADIR/GenomeWideSNP_6.canary_offsets /home2/jason/birdsuite/EXEDIR/canary.R /home2/jason/birdsuite/TEST_OUT/test.canary_log
I have 2 questions:
1. How do I define the path for R? (in bashrc for example) So that when I type "R" in the command line it'll know where to look instead of me typing out the entire path for R.
2. the canary.R file, above, contains the following at the beginning:
# /broad/tools/bin/R CMD BATCH \
# method = "GMM"
# outDir = "out"
# verbose = T
I had originally thought that specifying the R path in this file would resolve the error, but no luck. Just wondering why specifying the R path in this .R file still lead to the unable to find R error?
Could anyone help me with these questions? Thanks very much!