Grid is an add-on package for the R language and environment for statistical computing and graphics. It provides a set of graphical functions which support a great deal of flexibility in the layout of graphics.
A couple of other R packages/projects make use of grid: Deepayan Sarkar's lattice (distributed with R as a "Recommended" package), Frank Harrell's Hmisc and Design, and M Kondrin's RGrace. I have also built a couple of packages on top of grid myself; see gridBase (available from CRAN) and gridSVG (available from my home page).
Grid is now part of the base R distribution (i.e., it is distributed and installed as part of the standard R distribution).
On this page you will find package downloads for older versions of grid, information on the compatibility of different versions of grid and R, and lots of documentation for grid.
I also have a todo list which describes some of my future plans for the development of grid.
The latest version is distributed with R.
You could try looking for a binary version for Windows here.
grid version | lattice version | R version |
0.5 or 0.5-1 | 0.4-0 | 1.4.* |
0.6 or 0.6-1 | 0.5-3 | 1.5.* |
0.7-1 | 0.5-6 | 1.6.* |
0.7-4 | 0.6-7 | 1.6.* or 1.7.* |
From R 1.8.0 on, new grid versions are released with new versions of R, which alleviates the problem of which grid version to use.
Documentation for grid is now distributed with the package as a series of vignettes -- type vignette() to see the list of available topics and vignette("<topic>") to view a PDF file describing the topic.
The vignettes are also available below, plus there are some extra bits and pieces that are not distributed with R. There are also links to more general overview articles, and a very short FAQ.
If you are interested in the future development of grid, there is also a list of plans and "todo"s.
These documents correspond to the latest released verion of R, but there are links to older versions of the documentation (corresponding to previous versions of R going back to 1.8.*).
grid.move.to
and grid.line.to
(R 1.8).
"null"
units.
There is also an article on grid in Volume 2/2, June 2002 of the R News newsletter. In that article, the last example cannot be run because I rather stupidly used a private data set. Here is an R script that includes the data and the grid code for that example; you should be able to simply cut-and-paste or save-and-source() this to reproduce the figure. Thanks to Wendy Wrapson and Dr Niki Harre from the Department of Psychology at the University of Auckland for allowing me to make the data set available.
Another R News article (Volume 3/2, October 2003) discusses the integration of grid graphics with the default base graphics system using the gridBase package.
Yet another R News article (Volume 5/1, May 2005) provides an update on changes in grid mainly introduced in R Version 2.0.0.
There are also slides from some talks on grid. One given at UBC (Vancouver) and York University (Toronto) 2003, one given at a workshop at the ISM (Tokyo) 2003) on future graphics development, which includes some information on the future of grid graphics, and one at the first useR! conference in Vienna.
Finally, there is my book, R Graphics, Part II of which is on grid.