I am trying to get a script to start automatically when I run the GUI version of R version 1.9.0, started from a .bat file (WINDOWS), but I'm getting strange errors In version 1.8.1 I was able to run a script automatically by copying the script into the file .Rprofile and running Rgui from a .bat script, but in version 1.9.0 I'm getting errors like: Error in inherits(x, "factor") : couldn't find function "winMenuNames" In addition: Warning message: In the method signature for function "contents", class "environment" has no current definition in: matchSignature(signature, fdef, where) Error in library(Biobase) : .First.lib failed Does anyone know if anything changed in version 1.9.0 that could explain these errors? Thanks Thon P.S. Below you find the script I use. %1 will contain the script that I try to run... ------------- @echo off copy %1 .Rprofile > copy-output.txt shift :Loop IF "%1" == "" GOTO Continue set %1=%2 shift shift GOTO Loop :Continue cat.exe > GS_R_in.txt "C:\Program Files\R\rw1090\bin\Rgui.exe" --no-save --no-restore cat.exe < GS_R_out.txt del GS_R_in.txt GS_R_out.txt copy-output.txt .Rprofile -----------
Prof Brian Ripley
2004-May-23 07:23 UTC
[R] Running scripts automatically from Rgui (Windows)
Please do read the NEWS file for R 1.9.0, which not only tells you this will happen but also tells you how to do this properly. On Sun, 23 May 2004, Thon de Boer wrote:> I am trying to get a script to start automatically > when I run the GUI version of R version 1.9.0, started > from a .bat file (WINDOWS), but I'm getting strange > errors > > In version 1.8.1 I was able to run a script > automatically by copying the script into the file > .Rprofile and running Rgui from a .bat script, but in > version 1.9.0 I'm getting errors like: > > Error in inherits(x, "factor") : couldn't find > function "winMenuNames" > In addition: Warning message: > In the method signature for function "contents", class > "environment" has no current definition in: > matchSignature(signature, fdef, where) > Error in library(Biobase) : .First.lib failed > > Does anyone know if anything changed in version 1.9.0 > that could explain these errors?There is a NEWS file, and this was also in the announcement of 1.9.0. Also so discussion on R-help at about the time of release. How did you manage to miss them? -- Brian D. Ripley, ripley at stats.ox.ac.uk 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