In this video we illustrate how to use the hist() function to plot histograms in R, and we illustrate the use and effects of some of its options (breaks and freq). We also show how to overlay a fitted parametric density (e.g., the best fitting normal density) or fitted nonparametric density. In addition, ,we show how to create side-by-side box plots with the boxplot() function including a fancy example with grouped side-by-side box plots that involves some nice enhancements of the standard display that boxplot() would produce. Examples in this video are drawn from Mod12Script.R. You should open
this script in RStudio and follow along, reading and submitting code as
you watch the video.
The hist() and boxplot() functions are easy to learn, but this video covers some techniques that go beyond the basic use of these functions, so you should definitely watch it.