封面
版权页
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Support files eBooks discount offers and more
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Chapter 1. R Graphics
Base graphics using the default package
Trellis graphs using lattice
Graphs inspired by Grammar of Graphics
Chapter 2. Basic Graph Functions
Introduction
Creating basic scatter plots
Creating line graphs
Creating bar charts
Creating histograms and density plots
Creating box plots
Adjusting x and y axes' limits
Creating heat maps
Creating pairs plots
Creating multiple plot matrix layouts
Adding and formatting legends
Creating graphs with maps
Saving and exporting graphs
Chapter 3. Beyond the Basics – Adjusting Key Parameters
Introduction
Setting colors of points lines and bars
Setting plot background colors
Setting colors for text elements – axis annotations labels plot titles and legends
Choosing color combinations and palettes
Setting fonts for annotations and titles
Choosing plotting point symbol styles and sizes
Choosing line styles and width
Choosing box styles
Adjusting axis annotations and tick marks
Formatting log axes
Setting graph margins and dimensions
Chapter 4. Creating Scatter Plots
Introduction
Grouping data points within a scatter plot
Highlighting grouped data points by size and symbol type
Labeling data points
Correlation matrix using pairs plots
Adding error bars
Using jitter to distinguish closely packed data points
Adding linear model lines
Adding nonlinear model curves
Adding nonparametric model curves with lowess
Creating three-dimensional scatter plots
Creating Quantile-Quantile plots
Displaying the data density on axes
Creating scatter plots with a smoothed density representation
Chapter 5. Creating Line Graphs and Time Series Charts
Introduction
Adding customized legends for multiple-line graphs
Using margin labels instead of legends for multiple-line graphs
Adding horizontal and vertical grid lines
Adding marker lines at specific x and y values using abline
Creating sparklines
Plotting functions of a variable in a dataset
Formatting time series data for plotting
Plotting the date or time variable on the x axis
Annotating axis labels in different human-readable time formats
Adding vertical markers to indicate specific time events
Plotting data with varying time-averaging periods
Creating stock charts
Chapter 6. Creating Bar Dot and Pie Charts
Introduction
Creating bar charts with more than one factor variable
Creating stacked bar charts
Adjusting the orientation of bars – horizontal and vertical
Adjusting bar widths spacing colors and borders
Displaying values on top of or next to the bars
Placing labels inside bars
Creating bar charts with vertical error bars
Modifying dot charts by grouping variables
Making better readable pie charts with clockwise-ordered slices
Labeling a pie chart with percentage values for each slice
Adding a legend to a pie chart
Chapter 7. Creating Histograms
Introduction
Visualizing distributions as count frequencies or probability densities
Setting the bin size and the number of breaks
Adjusting histogram styles – bar colors borders and axes
Overlaying a density line over a histogram
Multiple histograms along the diagonal of a pairs plot
Histograms in the margins of line and scatter plots
Chapter 8. Box and Whisker Plots
Introduction
Creating box plots with narrow boxes for a small number of variables
Grouping over a variable
Varying box widths by the number of observations
Creating box plots with notches
Including or excluding outliers
Creating horizontal box plots
Changing the box styling
Adjusting the extent of plot whiskers outside the box
Showing the number of observations
Splitting a variable at arbitrary values into subsets
Chapter 9. Creating Heat Maps and Contour Plots
Introduction
Creating heat maps of a single Z variable with a scale
Creating correlation heat maps
Summarizing multivariate data in a single heat map
Creating contour plots
Creating filled contour plots
Creating three-dimensional surface plots
Visualizing time series as calendar heat maps
Chapter 10. Creating Maps
Introduction
Plotting global data by countries on a world map
Creating graphs with regional maps
Plotting data on Google maps
Creating and reading KML data
Working with ESRI shapefiles
Chapter 11. Data Visualization Using Lattice
Introduction
Creating bar charts
Creating stacked bar charts
Creating bar charts to visualize cross-tabulation
Creating a conditional histogram
Visualizing distributions through a kernel-density plot
Creating a normal Q-Q plot
Visualizing an empirical Cumulative Distribution Function
Creating a boxplot
Creating a conditional scatter plot
Chapter 12. Data Visualization Using ggplot2
Introduction
Creating bar charts
Creating multiple bar charts
Creating a bar chart with error bars
Visualizing the density of a numeric variable
Creating a box plot
Creating a layered plot with a scatter plot and fitted line
Creating a line chart
Graph annotation with ggplot
Chapter 13. Inspecting Large Datasets
Introduction
Multivariate continuous data visualization
Multivariate categorical data visualization
Visualizing mixed data
Zooming and filtering
Chapter 14. Three-dimensional Visualizations
Introduction
Three-dimensional scatter plots
Three-dimensional scatter plots with a regression plane
Three-dimensional bar charts
Three-dimensional density plots
Chapter 15. Finalizing Graphs for Publications and Presentations
Introduction
Exporting graphs in high-resolution image formats – PNG JPEG BMP and TIFF
Exporting graphs in vector formats – SVG PDF and PS
Adding mathematical and scientific notations (typesetting)
Adding text descriptions to graphs
Using graph templates
Choosing font families and styles under Windows Mac OS X and Linux
Choosing fonts for PostScripts and PDFs
Index
更新时间:2021-08-05 17:31:03