On Tue, 13 Nov 2007, Muiser, EC wrote:

> Thank you very much Alberto! Atleast I can see there is an error now.
> The error however is strange. If I load the library in an R console it works 
> perfectly but the package seems not to exist if I run R from a script. The 
> library should be there.
>
> Errorlog:
>
> Error in library(tgp) : there is no package called 'tgp'
> Execution halted
>
> more suggestions?

Read ?Startup : the startup files read depend on the working directory and 
the account.  I expect one of them sets the library (the real meaning of 
the word, you do not 'load the library': you load packages) path or the 
R_LIBS environment variable.

Please (both of you) stop sending mail to both [EMAIL PROTECTED] 
and r-help@r-project.org: they are the same thing.

> Iwe Muiser
>
> ---------------------------------------------
> Iwe E.C. Muiser, Student Bio-Informatics
> Hanze Hogeschool Groningen
> The Netherlands
> Tel +31645700419
> E-mail [EMAIL PROTECTED]
> ---------------------------------------------
>
> ________________________________
>
> Fra: Alberto Monteiro [mailto:[EMAIL PROTECTED]
> Sendt: ti 13-11-2007 14:23
> Til: Muiser, EC; [EMAIL PROTECTED]
> Kopi: r-help@r-project.org
> Emne: Re: [R] script fails because of library loading
>
>
>
>
> Muiser, EC wrote:
>>
>> The php script executes the following command: "/usr/bin/R --quiet --
>> slave < /perl/outfiles/Rscript19785065.R
>> /perl/outfiles/error19785065.txt"
>
>> Also there is no errorlog (in
>> "/perl/outfiles/error19785065.txt")
>
> This part is easy: the error output should go to 2> and not to >,
> like this:
>
> "/usr/bin/R --quiet --slave < /perl/outfiles/Rscript19785065.R
> > /perl/outfiles/error19785065.txt 2> error.log"
>
> Alberto Monteiro
>
> ______________________________________________
> R-help@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>

-- 
Brian D. Ripley,                  [EMAIL PROTECTED]
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to