## Lattice: Multivariate Data Visualization with RR is rapidly growing in popularity as the environment of choice for data analysis and graphics both in academia and industry. Lattice brings the proven design of Trellis graphics (originally developed for S by William S. Cleveland and colleagues at Bell Labs) to R, considerably expanding its capabilities in the process. Lattice is a powerful and elegant high level data visualization system that is sufficient for most everyday graphics needs, yet flexible enough to be easily extended to handle demands of cutting edge research. Written by the author of the lattice system, this book describes it in considerable depth, beginning with the essentials and systematically delving into specific low levels details as necessary. No prior experience with lattice is required to read the book, although basic familiarity with R is assumed. The book contains close to150 figures produced with lattice. Many of the examples emphasize principles of good graphical design; almost all use real data sets that are publicly available in various R packages. All code and figures in the book are also available online, along with supplementary material covering more advanced topics. |

### What people are saying - Write a review

This is a very well written book designed to help R users take their graphing ability to the next level. Examples have been well chosen to illustrate capabilities of lattice, yet simple enough for the reader to understand.

Graphs with conditioning and grouping variables are a very powerful analytical tool. After reading this book, I am able to draw far more informative and aesthetically pleasing graphs.

### Contents

721 Nonstandard settings | 128 |

73 Nongraphical options | 130 |

Plot Coordinates and Axis Annotation | 132 |

82 The scales argument | 133 |

Ticks and labels | 134 |

823 Defaults | 137 |

cloud and wireframe | 138 |

83 Limits and aspect ratio | 139 |

10 | |

11 | |

14 | |

15 | |

221 Aspect ratio | 18 |

222 Layout | 19 |

between and skip | 23 |

Captions labels and legends | 25 |

25 Graphing the data | 27 |

252 The panel function | 29 |

253 The panel function demystiﬁed | 30 |

26 Return value | 32 |

Visualizing Univariate Distributions | 33 |

32 Large datasets | 36 |

33 Histograms | 38 |

34 Normal QQ plots | 39 |

341 Normality and the BoxCox transformation | 41 |

342 Other theoretical QQ plots | 42 |

35 The empirical CDF | 43 |

37 Boxandwhisker plots | 46 |

38 Strip plots | 49 |

39 Coercion rules | 51 |

310 Discrete distributions | 52 |

311 A note on the formula interface | 53 |

Displaying Multiway Tables | 54 |

42 Bar chart | 56 |

421 Manipulating order | 60 |

422 Bar charts and discrete distributions | 62 |

43 Visualizing categorical data | 64 |

Scatter Plots and Extensions | 66 |

52 Advanced indexing using subscripts | 70 |

53 Variants using the type argument | 74 |

531 Superposition and type | 78 |

54 Scatterplot variants for large data | 81 |

55 Scatterplot matrix | 83 |

551 Interacting with scatterplot matrices | 85 |

56 Parallel coordinates plot | 86 |

Trivariate Displays | 90 |

611 Dynamic manipulation versus stereo viewing | 94 |

612 Variants and panel functions | 95 |

62 Surfaces and twoway tables | 97 |

621 Data preparation | 98 |

622 Visualizing surfaces | 101 |

623 Visualizing discrete array data | 104 |

63 Theoretical surfaces | 109 |

631 Parameterized surfaces | 110 |

64 Choosing a palette for falsecolor plots | 112 |

Finer Control | 115 |

Graphical Parameters and Other Settings | 116 |

711 Themes | 119 |

713 Initializing a graphics device | 120 |

714 Reading and modifying a theme | 121 |

715 Usage and alternative forms | 124 |

72 Available graphical parameters | 125 |

832 Explicit specification of limits | 140 |

833 Choosing aspect ratio by banking | 142 |

84 Scale components and the axis function | 143 |

842 Axis | 147 |

Labels and Legends | 150 |

92 Legends | 151 |

922 The colorkey argument | 154 |

923 The key argument | 155 |

924 The problem with settings and the autokey argument | 157 |

925 Dropping unused levels from groups | 158 |

The legend argument | 160 |

93 Page annotation | 161 |

Data Manipulation and Related Topics | 163 |

102 The extended formula interface | 164 |

103 Combining data sources with makegroups | 169 |

104 Subsetting | 172 |

1041 Dropping of factor levels | 175 |

105 Shingles and related utilities | 176 |

1051 Coercion to factors and shingles | 181 |

1052 Using shingles for axis breaks | 182 |

1053 Cutandstack plots | 183 |

106 Ordering levels of categorical variables | 186 |

107 Controlling the appearance of strips | 192 |

108 An Example Revisited | 197 |

Manipulating the trellis Object | 200 |

112 The plot printand summary methods | 201 |

113 The update method and trellislastobject | 205 |

114 Tukey meandifference plot | 207 |

115 Specialized manipulations | 209 |

116 Manipulating the display | 210 |

Interacting with Trellis Displays | 213 |

1211 Interaction | 215 |

123 Interactive additions | 216 |

124 Other uses | 222 |

Extending Trellis Displays | 226 |

Advanced Panel Functions | 227 |

1312 Accessor functions | 230 |

1313 Arguments | 231 |

133 Some more examples | 234 |

1332 A modiﬁed boxandwhisker plot | 236 |

1333 Corrgrams as customized level plots | 237 |

134 Threedimensional projections | 240 |

135 Maps | 241 |

1351 A simple projection scheme | 243 |

1352 Maps with conditioning | 244 |

New Trellis Displays | 246 |

141 S3 methods | 247 |

142 S4 methods | 248 |

143 New functions | 250 |

Multipanel pie charts | 251 |

References | 254 |

258 | |