| 31783 |
murdoch |
1 |
R @FULLVERSION@ for Windows
|
| 8379 |
ripley |
2 |
===================
|
| 4742 |
ripley |
3 |
|
| 8497 |
ripley |
4 |
This distribution contains a binary distribution of R-@RVER@ to run on
|
| 81902 |
ligges |
5 |
64-bit versions of Windows 7 and later on x86_64 chips.
|
| 81899 |
ligges |
6 |
It is designed to be as close as possible to the
|
| 59352 |
ripley |
7 |
implementation on Unix, but see the list of differences below. The
|
|
|
8 |
port was by Guido Masarotto, Brian Ripley and Duncan Murdoch.
|
| 4742 |
ripley |
9 |
|
|
|
10 |
|
|
|
11 |
Installation
|
|
|
12 |
============
|
|
|
13 |
|
| 59352 |
ripley |
14 |
The distribution is distributed as an installer @RWVER@-win.exe. Just
|
| 61492 |
ripley |
15 |
run this for a Windows-style installer.
|
| 13633 |
ripley |
16 |
|
| 59352 |
ripley |
17 |
For more details, including command-line options for the installer and
|
|
|
18 |
how to uninstall, see the rw-FAQ. If you are reading this as part of
|
| 59671 |
ripley |
19 |
an installed version of R, that is both a file rw-FAQ in this directory
|
|
|
20 |
and a file doc\html\rw-FAQ.html.
|
| 13633 |
ripley |
21 |
|
| 22650 |
ripley |
22 |
|
| 4742 |
ripley |
23 |
Usage
|
|
|
24 |
=====
|
|
|
25 |
|
|
|
26 |
GUI:
|
|
|
27 |
|
|
|
28 |
Rgui.exe runs as a standard Windows GUI executable and provides an R
|
| 9961 |
ripley |
29 |
console in its own window. It takes the standard R command-line
|
| 5429 |
ripley |
30 |
arguments; these are most easily set by making a shortcut to
|
| 81899 |
ligges |
31 |
...\@RWVER@\bin\x64\Rgui.exe and adding the
|
| 54534 |
ripley |
32 |
arguments in the Target field. Set the 'Start in' field of the
|
|
|
33 |
shortcut to the directory you want to use as the working directory
|
|
|
34 |
(where workspaces and files are saved to and loaded from). The
|
|
|
35 |
installer creates a shortcut on the desktop for you (by default).
|
| 4742 |
ripley |
36 |
|
| 14489 |
ripley |
37 |
You have a choice of interface: SDI (separate windows) or MDI
|
|
|
38 |
(multiple child windows in one large window). MDI is the default:
|
| 43545 |
ripley |
39 |
select SDI by adding --sdi in the Target field: this can also be
|
|
|
40 |
selected from the installer.
|
| 13633 |
ripley |
41 |
|
| 4742 |
ripley |
42 |
Command-line editing is available: see Help | Console for details.
|
|
|
43 |
|
|
|
44 |
The menus provide shortcuts to some R commands such as help, help.start,
|
|
|
45 |
apropos, ls, load, save.image, search.
|
|
|
46 |
|
| 43545 |
ripley |
47 |
The 'load' menu items (Source R code, Display file, Load Workspace)
|
| 13931 |
ripley |
48 |
keep track of the directory that was last used, and start their dialog
|
|
|
49 |
boxes from that directory the next time they are used. That directory
|
|
|
50 |
can be made the working directory by the File | Change dir menu item.
|
| 52246 |
ripley |
51 |
All the 'save' menu items start dialog boxes at the current working
|
|
|
52 |
directory: this includes 'Save Workspace' and the various ways to save
|
| 11635 |
ripley |
53 |
graphics, as well as saving the workspace at the end of the session.
|
| 4742 |
ripley |
54 |
|
| 52246 |
ripley |
55 |
Note that a few of the text help files use accented Western European.
|
|
|
56 |
To see all the characters you must use an appropriate font
|
|
|
57 |
(European-language True Type fonts should be OK). To check if your
|
|
|
58 |
preferred font has these characters, try "help(text)" and look at the
|
|
|
59 |
examples.
|
| 4742 |
ripley |
60 |
|
|
|
61 |
|
|
|
62 |
TERMINAL/BATCH:
|
|
|
63 |
|
| 52246 |
ripley |
64 |
Rterm.exe will run from a command line such as a 'Command Prompt'
|
|
|
65 |
window running the standard shell, cmd.exe, as well as the ports of
|
| 43545 |
ripley |
66 |
bash and tcsh that we use. Its primary purpose is to allow batch
|
|
|
67 |
operation, but it does provide all the facilities needed for
|
|
|
68 |
interactive use, including command-line editing (see the file
|
|
|
69 |
README.Rterm).
|
| 4742 |
ripley |
70 |
|
| 9324 |
ripley |
71 |
Batch use: At its simplest, Rterm.exe can be used in a batch mode by
|
| 4742 |
ripley |
72 |
commands like
|
|
|
73 |
|
| 26251 |
ripley |
74 |
Rterm.exe --no-restore --no-save < infile > outfile 2>&1
|
| 4742 |
ripley |
75 |
|
| 43545 |
ripley |
76 |
although users will probably want to set up simple .bat or .cmd files
|
|
|
77 |
to run batch jobs. You can also use it via R CMD BATCH: see ?BATCH or
|
|
|
78 |
R CMD BATCH --help.
|
| 4742 |
ripley |
79 |
|
| 9324 |
ripley |
80 |
Use with ESS: You can use Rterm.exe to provide inferior R-mode in ESS
|
| 59352 |
ripley |
81 |
under NTEmacs. The pager is automatically set to "console" so text
|
|
|
82 |
help will be displayed in emacs buffers.
|
| 4742 |
ripley |
83 |
|
|
|
84 |
|
|
|
85 |
GRAPHICS:
|
|
|
86 |
|
| 59352 |
ripley |
87 |
The screen device is called windows(). This is launched
|
|
|
88 |
automatically, and can also be launched explicitly by windows() from
|
|
|
89 |
both Rgui.exe and Rterm.exe. A printer device can be opened using
|
|
|
90 |
win.print(), and graphs drawn as metafiles by win.metafile().
|
| 4742 |
ripley |
91 |
|
| 9961 |
ripley |
92 |
The graphics device pops up a separate window which has two menus. The
|
| 5621 |
ripley |
93 |
device's File menu allows saving or printing or to run dev.off().
|
| 4742 |
ripley |
94 |
|
| 9961 |
ripley |
95 |
The History menu allows the recording of plots. When plots have been
|
| 4742 |
ripley |
96 |
recorded they can be reviewed by PgUp and PgDn, saved and replaced.
|
|
|
97 |
Recording can be turned on automatically (the Recording item on the
|
|
|
98 |
list) or individual plots can be added (Add or the INS key).
|
| 30649 |
murrell |
99 |
|
| 4742 |
ripley |
100 |
The whole plot history can be saved to or retrieved from an R variable
|
|
|
101 |
in the global environment.
|
| 30649 |
murrell |
102 |
The format of recorded plots may change between R versions.
|
|
|
103 |
Recorded plots should NOT be used as a permanent
|
|
|
104 |
storage format for R plots.
|
| 4742 |
ripley |
105 |
|
|
|
106 |
There is only one graphics history shared by all the windows devices.
|
|
|
107 |
|
| 8390 |
ripley |
108 |
|
| 4742 |
ripley |
109 |
Customization
|
|
|
110 |
=============
|
|
|
111 |
|
| 11075 |
ripley |
112 |
Environment variables can be set as NAME=value at the end of the
|
|
|
113 |
command line, including in a shortcut. They can also be set (as
|
|
|
114 |
NAME=value lines) in the file .Renviron in the working directory, or
|
|
|
115 |
if that does not exist HOME\.Renviron.
|
| 4742 |
ripley |
116 |
|
| 8379 |
ripley |
117 |
Many aspects of the console (size, appearance, font, font size,
|
|
|
118 |
colours) can be customized by editing the file etc\Rconsole, and a
|
|
|
119 |
copy with a user's settings can be put in her HOME directory or in the
|
| 9961 |
ripley |
120 |
working directory. (The exact sequence is to search the directory
|
| 8379 |
ripley |
121 |
pointed to by the first found of the environment variables R_USER then
|
| 59352 |
ripley |
122 |
HOME, then the Windows "personal" directory (typically
|
| 81902 |
ligges |
123 |
'C:\Users\username\My Documents' on recent versions of Windows) then
|
| 61492 |
ripley |
124 |
{HOMEDRIVE}{HOMEPATH} then the working directory, finally R_HOME\etc.
|
|
|
125 |
This also applies to .Renviron and other uses of 'HOME' in our
|
|
|
126 |
documentation.) The file contains a description of the settings that
|
|
|
127 |
can be altered. See also ?Rconsole.
|
| 4742 |
ripley |
128 |
|
| 8991 |
ripley |
129 |
An alternative way to edit the Rconsole file is to use the GUI
|
|
|
130 |
preferences item on the Edit menu in Rgui.exe. This can change some
|
|
|
131 |
of the settings (for example colours, font and window sizes) on the
|
|
|
132 |
current running console.
|
|
|
133 |
|
| 13825 |
ripley |
134 |
The mapping between Windows fonts and the font number used in R's
|
|
|
135 |
graphics can be set by editing the file etc\Rdevga, and a copy with a
|
|
|
136 |
user's settings can be put in the HOME or working directory (see the
|
|
|
137 |
description of Rconsole). This mapping applies to both the screen
|
|
|
138 |
device and the printer device.
|
| 4742 |
ripley |
139 |
|
|
|
140 |
Many R defaults can be set in the file R_HOME\etc\Rprofile or a user's
|
| 9961 |
ripley |
141 |
file .Rprofile. In particular:
|
| 4742 |
ripley |
142 |
|
| 59352 |
ripley |
143 |
- The pager is set by options(pager=). The default is "internal"
|
|
|
144 |
which brings up a separate console-like window. The internal pager
|
|
|
145 |
can use a single window or a different window for each topic shown
|
|
|
146 |
(configurable in Rconsole). Other possibilities we have used are
|
|
|
147 |
"notepad" and "console" to list the files in the console (Rgui.exe)
|
|
|
148 |
or terminal window (Rterm.exe).
|
| 4742 |
ripley |
149 |
|
|
|
150 |
|
|
|
151 |
Adding packages
|
|
|
152 |
===============
|
|
|
153 |
|
| 31801 |
ripley |
154 |
Binaries for many packages are available under
|
|
|
155 |
CRAN/bin/windows/contrib. These are zip files which should be
|
| 23826 |
ripley |
156 |
unpacked in @RWVER@\library. The simplest option is use the items on
|
|
|
157 |
the Packages menu to install from a zip file or to download from CRAN.
|
| 4742 |
ripley |
158 |
|
|
|
159 |
Private libraries of packages can be used and can be specified by the
|
| 9961 |
ripley |
160 |
environment variable R_LIBS. (Separate directories by ";" in this
|
| 4742 |
ripley |
161 |
version.) They will not be linked to HTML help. In more detail, to
|
| 5556 |
ripley |
162 |
use packages installed in directory R:\libraries\gm, set
|
| 4742 |
ripley |
163 |
|
| 6490 |
ripley |
164 |
R_LIBS=R:\libraries\gm
|
| 4742 |
ripley |
165 |
|
| 8379 |
ripley |
166 |
in the environment or your .Renviron file or on the command line, or
|
|
|
167 |
add the line
|
| 4742 |
ripley |
168 |
|
| 17198 |
hornik |
169 |
.libPaths("R:/libraries/gm")
|
| 4742 |
ripley |
170 |
|
| 6098 |
pd |
171 |
to your .Rprofile or at the end of R_HOME\etc\Rprofile.
|
| 4742 |
ripley |
172 |
|
|
|
173 |
To install a package from source code you need the source-package
|
| 34461 |
ripley |
174 |
distribution installed from @RWVER@-win32.exe (but not the R sources).
|
| 52246 |
ripley |
175 |
The 'R Installation and Administration' manual contains detailed
|
| 33027 |
murdoch |
176 |
instructions.
|
| 4742 |
ripley |
177 |
|
|
|
178 |
|
| 8390 |
ripley |
179 |
Differences from Unix versions of R
|
|
|
180 |
===================================
|
| 4742 |
ripley |
181 |
|
| 6490 |
ripley |
182 |
- R can be interrupted by Esc in Rgui and by Ctrl-C or Ctrl-Break in Rterm:
|
| 8390 |
ripley |
183 |
Ctrl-C is used for copying in the GUI version. C-c C-c works
|
| 6490 |
ripley |
184 |
under NTemacs.
|
| 4742 |
ripley |
185 |
|
| 9946 |
ripley |
186 |
- Command-line editing is always available, but is simpler than
|
|
|
187 |
under readline-based input on Unix. For Rgui.exe, see the menu item
|
| 52246 |
ripley |
188 |
'Help | Console', for Rterm.exe the file README.Rterm.
|
| 4742 |
ripley |
189 |
|
|
|
190 |
- Paths to files can be specified with "/" or "\\".
|
|
|
191 |
|
| 6098 |
pd |
192 |
- system() is enhanced here and does not automatically use a shell.
|
| 7913 |
ripley |
193 |
See its help page and that of shell().
|
| 4742 |
ripley |
194 |
|
| 9324 |
ripley |
195 |
- graphics device bmp() is available in this version.
|
| 4742 |
ripley |
196 |
|
| 6490 |
ripley |
197 |
|
| 9961 |
ripley |
198 |
Using package tcltk
|
|
|
199 |
===================
|
|
|
200 |
|
| 18146 |
ripley |
201 |
The package tcltk supports building graphical interfaces with Tcl/Tk.
|
| 47828 |
ripley |
202 |
"Support Files for Package tcltk" needs to be selected from the
|
| 23831 |
ripley |
203 |
installer for this to work; alternatively you can use an existing
|
| 70701 |
murdoch |
204 |
installation of Tcl/Tk 8.6.x by following the instructions in the
|
| 23831 |
ripley |
205 |
rw-FAQ.
|
| 9961 |
ripley |
206 |
|
|
|
207 |
|
| 4742 |
ripley |
208 |
Building From Source
|
|
|
209 |
====================
|
|
|
210 |
|
| 84215 |
maechler |
211 |
See the 'R Installation and Administration' Manual
|
| 59352 |
ripley |
212 |
(doc\manual\R-admin.html).
|
| 5556 |
ripley |
213 |
|
| 4742 |
ripley |
214 |
|
|
|
215 |
Feedback
|
|
|
216 |
========
|
|
|
217 |
|
| 18569 |
ripley |
218 |
Please send comments and bug reports to
|
| 4742 |
ripley |
219 |
|
| 18581 |
ripley |
220 |
R-windows@r-project.org
|
| 18569 |
ripley |
221 |
|