I have searched through the mailing lists and the docs, and I seem completely unable to find a way to make R list all available environment variables that it uses. The reason that I want to do this is the following: The default program for reading files when using openVignettes on my system is ggv. ggv is broken. I would therefore like to use a different program, and I found the variable R_PDFVIEWER which should do the trick. However, so far no luck. Therefore, how do I ask R what variables are available, and how do I get it to show what it is currently set to. Thanks! Karin, who is most likely going blind -- Karin Lagesen, PhD student karin.lagesen at medisin.uio.no http://folk.uio.no/karinlag
These retrieve and set environment variables: ?Sys.getenv ?Sys.putenv On 11/29/06, Karin Lagesen <karin.lagesen at medisin.uio.no> wrote:> > I have searched through the mailing lists and the docs, and I seem > completely unable to find a way to make R list all available > environment variables that it uses. > > The reason that I want to do this is the following: > > The default program for reading files when using openVignettes on my > system is ggv. ggv is broken. I would therefore like to use a > different program, and I found the variable R_PDFVIEWER which should > do the trick. However, so far no luck. > > Therefore, how do I ask R what variables are available, and how do I > get it to show what it is currently set to. > > Thanks! > > Karin, who is most likely going blind > -- > Karin Lagesen, PhD student > karin.lagesen at medisin.uio.no > http://folk.uio.no/karinlag > > ______________________________________________ > R-help at stat.math.ethz.ch 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. >
On Wed, 29 Nov 2006, Karin Lagesen wrote:> > I have searched through the mailing lists and the docs, and I seem > completely unable to find a way to make R list all available > environment variables that it uses. > > The reason that I want to do this is the following: > > The default program for reading files when using openVignettes on my > system is ggv. ggv is broken. I would therefore like to use a > different program, and I found the variable R_PDFVIEWER which should > do the trick. However, so far no luck. > > Therefore, how do I ask R what variables are available, and how do I > get it to show what it is currently set to.In this specific case you need to look at the R-admin manual for what various variables do, and Sys.getenv("R_PDFVIEWER") or Sys.getenv() for the current value or list of values. R_PDFVIEWER is set in R_HOME/etc/Renviron, and you can override the setting via ~/.Renviron (see ?Startup). -- 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
Karin Lagesen <karin.lagesen <at> medisin.uio.no> writes: ...> The default program for reading files when using openVignettes on my > system is ggv. ggv is broken. I would therefore like to use a > different program, and I found the variable R_PDFVIEWER which should > do the trick. However, so far no luck. > > Therefore, how do I ask R what variables are available, and how do I > get it to show what it is currently set to.Try options(pdfviewer="something") Gregor