1.2 Overview of the book structure

  • The book is composed of five sections. A step by step path towards mastering R techniques.
  • The Foundations is the part in which the R components will be examined. It will help understanding how to use all the basics tools to deal with functions and structures.
  • The Functional programming goes a little more in dept into programming with R, making functions of functions. Describing function factories and operators.
  • The Object-oriented programming - OOP is a five chapter section, all about object oriented systems among S3, R6 and S4.
  • The Metaprogramming section introduces you through the programming layers.
  • Finally, the Techniques section is dedicated to finding and fixing bugs and improving performances.

1.2.1 What this book is not

  • This book is about the R programming language, not R as the data analysis tool.
  • We will not be discussing package development at length.
  • Some experience using R will be helpful.
    • I encourage all to participate, though.

1.2.2 Organization of the book

Foundations
Functional programming
Object-oriented programming
Metaprogramming
Techniques

1.2.3 Foundations

Six chapters to learn the foundational components of R.
Foundations
Names and values
Control flow
Functions
Vectors
Subsetting
Environment
Conditions

The last chapter “conditions” describe errors, warnings, and messages.

1.2.4 Functional programming

This part of the book is dedicated to functions: function factories and operators.

Functional programming
Functionals
Function factories
Function operators

1.2.5 Object-oriented programming

OOP is the most dense part of the book, as it mentions about systems which interact with R.

Object-oriented programming
Base types
S3
R6
S4
Trade-offs

1.2.6 Metaprogramming

This is the part of the book where things are blended to the Big Picture. R is a versatile functional language that can be managed and assembled.

Metaprogramming
Big Picture
Expressions
Quasiquotation
Evaluation
Translating R code

1.2.7 Techniques

Finally, this is the last section of the book, where debugging is used to measure and improve performance. And how to improve performance by rewriting key functions in C++.

Techniques
Debugging
Measuring performance
Improving performance
Rewriting R code in C++