Skip to content
Back to formatted view

Raw Message

Message-ID: <99F44D6A-8EFD-45A6-869B-439AC34DAC37@unive.it>
Date: 2006-11-30T08:58:30Z
From: nicola sartori
Subject: system() from R.app

Dear all,

I have a question on the use of system(command) from R.app:
if I try, for instance, to do:

system("latex foo.tex")

I get the following output in the console:

/bin/sh: line 1: latex: command not found

While if I do the same thing running R from the terminal (or xterm  
under X11) it works just fine.
I guess the reason is that, when in the terminal, the path is set by  
my shell init file (which, incidentally, is bash) while this doesn't  
happen when in R.app.
By the way, running latex is not a big issue: I can get the right  
path from options(), but for other commands the problem will still be  
there

Is there a workaround for this?

Thanks in advance for any help.

Best,
Nicola