[R] problem with Rscript
m.u.r.
mmuurr at gmail.com
Wed Mar 25 00:10:23 CET 2009
Hi all, this is probably some tricky configuration file problem, but I
figure someone here might have come across this in the past:
In short, I've been using Rscript to run my scripts, usually
successfully. But recently I've run into a strange problem, and the
only function that causes an error is "print".
I can create a file that contains only a print command, and it causes
an error. Here is a test file, called "test.R":
print(69)
That's it, just the single print line in the file. Now, when I try to
execute this file using Rscript (using the same flags I've used
successfully in the past):
Rscript --restore --no-save test.R
I get this error:
Error in print(69) : could not find function "loadMethod"
Execution halted
This problem seems to be isolated to Rscript, not R, as the following
command works just fine:
R --restore --no-save < test.R
has anyone ever seen anything like this with Rscript? And maybe shed
some light on why "loadMethod" can't be found when starting R via
Rscript?
Thanks,
Murat
More information about the R-help
mailing list