On Mon, 27 Feb 2006, javier garcia-pintado wrote:
> Thank you very much Prof Brian R,
> I also wonder how I missed that.
> Anyway, In my .Rprofile file:
>> .First <- function() cat ("\n Welcome to R!\n")
> works perfectly, while:
>> .First <- function() winMenuAdd("Newmenu")
> give me the answer:
> "Error in .First(): couldn't find function "winMenuAdd"
> I just can add the new menu, and create the menu entries later, calling a
> source() that adds the menus.
> Perhaps the functions to add menus to the RGUI are called after the .RProfile
> is red?
> To add it via the .Rprofile would be perfect, but anywat, to be able to
> create the menu calling manually a source after the GUI is completely
> started is good enough for me.
You need to specify the package at that point, as when .First is run the
default packages are not yet loaded (see ?Startup for the precise
description). E.g. (untested, as I am using Linux)
.First <- function() utils::winMenuAdd("Newmenu")
--
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
______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html