Raphael,
I too had problems setting up Tinn-R 2.3.5.2 with R 2.11.1-x64 in 64-bit
Windows 7. The following I had previously written to a colleague to show
how I resolved the problems. I'm not sure if any of this will be of help to
you, but Step 3 fixed an issue I was having with .trPaths.
Cheers,
Jeremy
Jeremy Hetzel
Boston University
1) Change permissions for the C:\Users\$USER\AppData\Roaming\Tinn-R
directory.
Windows 7 makes this directory read-only by default, but Tinn-R
expects to be able to write to it, causing errors. For me, I went to
C:\Users\jthetzel\AppData\Roaming, right-clicked the Tinn-R directory,
and un-checked the 'Read-only' attribute.
2) Run Tinn-R as administrator
I found that if I went back to the ...Roaming\Tinn-R directory later,
Windows had reset the attribute to 'Read-only'. So, far good measure,
I also changed the Tinn-R.exe file under C:\Program Files (x86)\Tinn-R
\bin\ to run as administrator. Browse to the directory, right-click
the Tinn-R.exe file, select properties, click the Compatibility tab,
and check the Run as Administrator box. Having accomplished step 2),
step 1) is probably unnecessary. But I include it here just because
it's what I did, and Tinn-R magically works again.
3) Change Options>Application>R>Rgui>Type to 'Partial' from
'Whole' in
Tinn-R, via the menu bar
Steps 1) and 2) addressed the problem where Tinn-R would complain
about '.trPaths' when sending code to R. However, I had the
additional problem of Tinn-R refusing to even attempt to send code to
R (the 'R send file' and 'R send selection' icons were dimmed
out).
Changing Options>Application>R>Rgui>Type to 'Partial' from
'Whole' in
Tinn-R, via the menu bar solved this problem. I don't know why.
The following is for anyone having problems with using Tinn-R with the
development R version 2.12.0x64. In the Windows development version I
downloaded, both the 32 and 64 bit R libraries were included.
Subsequently, the folder structure has changed, which Tinn-R does not
recognize by default.
4) Change Options>Application>R>Rterm.exe search path to wherever your
Rterm.exe is located.
For me, it was C:\Program Files\R\R-2.12.0dev\bin\x64\Rterm.exe
5) Change Options>Application>R>Rgui.exe search path to wherever your
Rgui.exe is located.
For me, it was C:\Program Files\R\R-2.12.0dev\bin\x64\Rgui.exe
6) Set 'Options>Application>R> Use latest installed version
(always)'
to 'No' from 'Yes'
If this is not changed, Tinn-R will try to reconfigure itself every
time it is re-opened to use the most recent installed R. Since it is
not familiar with the change in folder structure in the development
version, it will fail.
7) Copy ...R-2.12.0dev\etc\Rprofile.site file to ...R-2.12.0dev\bin
\etc\Rprofile.site
Tinn-R expects the Rprofile.site file to be in the ..\etc folder,
relative to wherever Rgui.exe or Rterm.exe are. However, in the new
folder structure, the etc folder is actually located at ..\..\etc,
relative to Rgui.exe and Rterm.exe. I could not find anywhere to
manually reconfigure the search path for the Rprofile.site file, so I
just created a new etc folder where Tinn-R is expecting it. In my
case, I created C:\Program Files\R\R-2.12.0dev\bin\etc and copied the
Rprofile.site file to it. For comparison, the contents of my
Rprofile.site file appears below. For some reason, every time I re-
start Tinn-R, it appends another copy of the Tinn-R configuration
lines to the Rprofile.site file. However, this behavior has not
caused any problems thus far.
#------ Example of my Rprofile.site file------#
# Things you might want to change
# options(papersize="a4")
# options(editor="notepad")
# options(pager="internal")
# set the default help type
# options(help_type="text")
options(help_type="html")
# set a site library
# .Library.site <- file.path(chartr("\\", "/", R.home()),
"site-
library")
# set a CRAN mirror
# local({r <- getOption("repos")
# r["CRAN"] <- "http://my.local.cran"
# options(repos=r)})
##==============================================================## Tinn-R:
necessary packages and functions
## Tinn-R: >= 2.2.0.2 with TinnR package >= 1.0.3
##==============================================================## Set the URL
of the preferred repository, below some examples:
options(repos='http://software.rc.fas.harvard.edu/mirrors/R/') # USA
#options(repos='http://cran.ma.imperial.ac.uk/') # UK
#options(repos='http://brieger.esalq.usp.br/CRAN/') # Brazil
library(utils)
## Check necessary packages
necessary <- c('TinnR', 'svSocket')
installed <- necessary %in% installed.packages()[, 'Package']
if (length(necessary[!installed]) >=1)
install.packages(necessary[!installed])
## Load packages
library(TinnR)
library(svSocket)
## Uncoment the two lines below if you want Tinn-R to always start R
at start-up
## (Observation: check the path of Tinn-R.exe)
#options(IDE='C:/Tinn-R/bin/Tinn-R.exe')
#trStartIDE()
## Set options
options(use.DDE=T)
## Start DDE
trDDEInstall()
.trPaths <- paste(paste(Sys.getenv('APPDATA'),
'\\Tinn-R\\tmp\\',
sep=''),
c('', 'search.txt', 'objects.txt',
'file.r',
'selection.r', 'block.r', 'lines.r'), sep='')
--
View this message in context:
http://r.789695.n4.nabble.com/Tinn-R-tp2952577p2953598.html
Sent from the R help mailing list archive at Nabble.com.