Description Usage Arguments Value Author(s) References Examples
Create a squareplot as an alternative to a segmented barplot. Useful when the viewer is interested in exact counts in the categories. A squareplot is often used by the New York Times. A grid of squares is presented with each color representing a different category. The colors appear contiguously reading top to bottom, left to right. The colors segment the graph as a segmented bargraph, but the squares allow an interested reader to easily tally the counts.
1 2 3 4 |
x |
a vector of counts |
col |
a vector of colors |
border |
border color passed to |
nrows |
number of rows |
ncols |
number of columns |
... |
passed to |
Creates the graph, but has no return value.
John Verzani
The New York Times, www.nytimes.com. In particular, Sports page 6, June 15, 2003.
1 2 | ## A Roger Clemens Cy Young year -- roids?
squareplot(c(21,7,6),col=c("blue","green","white"))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.