Utilities and Data Sets for Data Visualization

Supporting materials for a course and book on data visualization. It contains utility functions for graphs and several sample data sets. See Healy (2019) .


socviz

R buildstatus

This is an R package of datasets and utility functions to accompany Data Visualization: A Practical Introduction (Princeton University Press, 2026).

What’s in this Package

The socviz package contains about thirty datasets and a number of utility and convenience functions used in Data Visualization: A Practical Introduction and of use to people producing data visualizations with R and ggplot.

Installation

To install the package, you can follow the instructions in the Preface to the book. Alternatively, and at a minimum, first download and install R for MacOS, Windows or Linux, as appropriate. Launch R, then type the following code at the Console prompt (>), hitting return at the end of each line:


install.packages("socviz")

To install the development version of socviz, instead of install.packages("socviz") do the following:


remotes::install_github("kjhealy/socviz")

Once everything has downloaded and been installed (which may take a little while), load the socviz package:

library(socviz)

More about the Datasets and Functions

The included datasets and functions are documented in the package and at https://kjhealy.github.io/socviz/reference/.

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("socviz")

2.0.0 by Kieran Healy, 2 months ago


https://kjhealy.github.io/socviz/, https://github.com/kjhealy/socviz


Report a bug at https://github.com/kjhealy/socviz/issues


Browse source code at https://github.com/cran/socviz


Authors: Kieran Healy [aut, cre, cph]


Documentation:   PDF Manual  


MIT + file LICENSE license


Imports ggplot2, graphics, grid, magrittr, systemfonts, tibble


Suggested by RplotterPkg, gompertztrunc.


See at CRAN