The R Primer provides a collection of concise examples with solutions and interpretations of R problems frequently encountered by new users of this statistical software. The R Primer contains numerous examples that illustrate a specific situation, topic, or problem, including data importing, data management, classical statistical analyses, and high-quality graphical production. Each example is self-contained and includes R code that can be run exactly as shown, enabling results from the book to be replicated.
New to the Second Edition:
- Completely revised and updated with suggestions for using new and improved R packages
- Expanded with over 100 more pages
- New solutions for covering areas from web scraping over data wrangling to waffle plots and hanging rootograms.
- Additional intermediate and advanced topics in statistical data analysis including non-parametric statistics, random forests, penalized regression and curve smoothing.
The site contains source code, extra material and errata.
Summary
- Presents commonly encountered problems and solutions in R in a “cookbook” style
- Covers importing and transforming data, making statistical analyses, and creating graphics
- Provides an ideal introduction for beginning users of R
- Includes code for all examples
“This book provides a good introduction to R, using a clear layout and detailed, reproducible examples. An ideal tool for any new R user. … A wide range of topics are covered, making the book suitable for a variety of readers, from undergraduate students to professionals new to R … an extremely helpful introduction to a very useful statistical package.”
- Claire Keeble, Journal of Applied Statistics, 2012
About the author
Claus Thorn Ekstrøm is Professor at the Section of Biostatistics, University of Copenhagen where he teaches courses on statistics and R for beginners and advanced users. Professor Ekstrøm’s primary research interests lie within statistical genetics, genetic epidemiology, and bioinformatics, in particular genetic association studies, image analysis of microarray scans, and integrated analysis of gene expression and metabolic profile data.
Differences between the 1st and 2nd editions
The 2nd edition has updated the existing solutions to reflect new packages and improvements in R and an extra 33% material has been added.
Created by Claus Ekstrøm 2017, page last updated 24 October, 2020