Art of Stat

R Code

R code in the end-of-chapter sections

The 5th edition includes commented R code sections at the end of each chapter, under Chapter Summary. Each section contains the R code that replicates the analysis in the chapter. You can view the R code from all Chapter Summaries in the PDF below.

Browse the end-of-chapter R notesPDF · 842 KB▾

Your browser may not display the PDF inline. Open the PDF.

R scripts for over 100 examples from the book

For over one hundred examples from the book, there is an annotated PDF that walks through the R code and output, plus the raw R script to run yourself. Open a chapter to see its examples.
All files are available in the artofstat/RCode GitHub repository.

Chapter 11 example▾
Chapter 215 examples▾
Chapter 310 examples▾
Chapter 42 examples▾
Chapter 52 examples▾
Chapter 610 examples▾
Chapter 73 examples▾
Chapter 810 examples▾
Chapter 93 examples▾
Chapter 109 examples▾
Chapter 117 examples▾
Chapter 129 examples▾
Chapter 1310 examples▾
Chapter 147 examples▾
Chapter 154 examples▾