Togaware DATA MINING
Desktop Survival Guide
by Graham Williams
Google

Trellis Histogram

Multiple plots can be placed into a single plot using the lattice package. Here we also illustrate the use of the Roption[]color option of the histogram function, setting it to FALSE to obtain a transparent background.

Image rplot-histogram-trellis


library(lattice)
load("wine.Rdata")
trellis.device(width=7, height=5, new=FALSE, color=FALSE)
with(wine, histogram(~ Alcohol | Type))

http://rattle.togaware.com/code/rplot-histogram-trellis.R



Copyright © Togaware Pty Ltd
Support further development through the purchase of the PDF version of the book.
The PDF version is a formatted comprehensive draft book (with over 800 pages).
Brought to you by Togaware. This page generated: Sunday, 22 August 2010