[R] FW: two questions - function help and 32vs64 bit sessions

Fowler, Mark Mark.Fowler at dfo-mpo.gc.ca
Mon Jul 21 18:57:51 CEST 2014



-----Original Message-----
From: Fowler, Mark 
Sent: July 21, 2014 1:56 PM
To: 'Duncan Murdoch'
Subject: RE: [R] two questions - function help and 32vs64 bit sessions

The server doesn't shut down, it just kind of shuts everybody else down.
But your mention of TEMPDIR jostled some old memory cells awake, and
essentially answered the question. I do [did] a similar thing with
temporary directories as you discuss, just another directory location.
But that location (R_USER) disappeared when I upgraded (one or all of R
to 2 to 3, OS XP to 7, machine 34 to 62 bit). So R has to create a temp
dir by default. I think that default directory gets derailed during
network-wide system scans, thus Tuesdays and weekends for me.

Sys.getenv('R_USER')
[1] "C:\\Users\\fowlerm\\Documents"
> tempdir()
[1] "C:\\Users\\fowlerm\\AppData\\Local\\Temp\\1\\RtmpeqbLeR"

-----Original Message-----
From: Duncan Murdoch [mailto:murdoch.duncan at gmail.com]
Sent: July 21, 2014 11:55 AM
To: Fowler, Mark; r-help at stat.math.ethz.ch
Subject: Re: [R] two questions - function help and 32vs64 bit sessions

On 21/07/2014 9:40 AM, Fowler, Mark wrote:
> Hi Duncan,
> I tried your suggestion, but no luck. The first error is no surprise, 
> it just confirms the address is lost. The second line suggests it 
> worked, but it didn't. The session is still remembering the original
address.
>
> > tools::startDynamicHelp(FALSE) # shut it down
> Warning message:
> In file(out, "wt") :
>    cannot open file
> 'C:\Users\fowlerm\AppData\Local\Temp\1\RtmpK09I4B\Rhttpd26c04742884': 
> No such file or directory
> > tools::startDynamicHelp(TRUE)  # start it up
> starting httpd help server ... done

This is a different error than I thought you described.  I thought
something had shut down the server, but it looks like something has 
deleted your temporary directory.   You might be able to tell your OS 
not to do that (if it was the OS that did), or you can put your
temporary directory in a location that is less likely to get deleted,
e.g. by setting the TMPDIR environment variable to somewhere else before
you start R.  For example, I typically run with TMPDIR set to C:/temp
when I'm debugging things.

Duncan Murdoch

>
> -----Original Message-----
> From: Duncan Murdoch [mailto:murdoch.duncan at gmail.com]
> Sent: July 16, 2014 10:47 AM
> To: Fowler, Mark; r-help at stat.math.ethz.ch
> Subject: Re: [R] two questions - function help and 32vs64 bit sessions
>
> On 14/07/2014, 11:42 AM, Fowler, Mark wrote:
> > Hello,
> >
> >
> >
> > Two unrelated questions, and neither urgent.
> >
> >
> >
> > Windows 7, R 3.0.1. Using R Console, no fancy interface.
> >
> >
> >
> > The function help ultimately becomes lost to a session kept running 
> > for extended periods (days). I.e. with a new session if you invoke 
> > the
>
> > Help menu 'R functions (txt)...' it activates the html help and goes

> > to the named function page. This will work fine for at least a day, 
> > but typically the next day invoking the help menu in this fashion 
> > will
>
> > fail, as R looks for a temporary address it creates on your
computer.
> > This gets lost, possibly due to network administration activity. So 
> > then I save and start another session with same Rdata. Trivial 
> > enough but irritating. Anybody know how to restore the 'link'
> > without ending and restarting the session?
>
> I never have sessions that last that long, so I haven't tried this, 
> but I'd expect you could restart the help system in this way:
>
> tools::startDynamicHelp(FALSE) # shut it down
> tools::startDynamicHelp(TRUE)  # start it up
>
> Duncan Murdoch
>
> >
> >
> >
> > I have a mix of 32-bit and 64-bit requirements, with 64 the default.

> > I
>
> > became used to starting R sessions directly from the appropriate 
> > Rdata
>
> > workspaces. With the latest version I need to start from the generic

> > icon and then load the workspace if I want 32-bit. Anybody know a 
> > way to make the Rdata files keep track of which bit version they 
> > work with, or some trick that accomplishes the same objective? The 
> > 32-bit requirement is usually just RODBC, and the need for it is 
> > scattered over lots of workspaces. Again, trivial but a nuisance. A 
> > more pragmatic motive is to not oblige users of applications to 
> > think about
>
> > it. Any way to make a session switch 'bits' with a source file?
> >
> >
> >
> > Mark Fowler
> > Population Ecology Division
> > Bedford Inst of Oceanography
> > Dept Fisheries & Oceans
> > Dartmouth NS Canada
> > B2Y 4A2
> > Tel. (902) 426-3529
> > Fax (902) 426-9710
> > Email Mark.Fowler at dfo-mpo.gc.ca <mailto:Mark.Fowler at dfo-mpo.gc.ca>
> >
> >
> >
> >
> >
> >
> > 	[[alternative HTML version deleted]]
> >
> > ______________________________________________
> > R-help at 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.
> >
>



More information about the R-help mailing list