RSQUARED ACADEMY • OPEN TEXTBOOK SERIES

Open Access R Books

Six open-access textbooks authored by Aravind Hebbali — from your first R script to wrangling, visualization, databases, and the command line. Fully reproducible code + data. CC BY-NC-SA.

6 booksCore Track 01–04 + 2 CompanionsR • dplyr • ggplot2 • SQL • BashBeginner → IntermediateFree online • Open Access

Learning path — core + companions

Follow the Core Track end to end. Take Bash alongside book 01 — it is environment tooling, not an advanced capstone. Take Base R graphics after ggplot2 only if you need fine-grained canvas control.

CORE 01

Intro to R

BeginnerZero to running code. RStudio, packages, help.

CORE 02

Data Wrangling

Beginner→ Int.Import, reshape, dplyr, pipes, tibbles.

CORE 03

Viz with ggplot2

IntermediateGrammar of graphics through to publication polish.

CORE 04

R, Databases & SQL

IntermediateDBI, dbplyr, queries, joins.

Shortcut: already wrangling data in SQL? take 04 right after 02.

COMPANION A — Foundational Tooling

Command Line Basics

BeginnerFiles, permissions, pipes and scripting for R users. Pair with Core 01.
On Windows: everything works from the RStudio Terminal, Git Bash or WSL — chapter 1 covers all three.

COMPANION B — Graphics Deep-Dive

Data Viz with Base R

IntermediateBase graphics engine, parameters, multi-panel layouts, production export. Zero dependencies. After Core 03.

The library

All 6 books

Introduction to R — Rsquared Academy R Series, Core Track 01
CORE 01

Introduction to R

Install R & RStudio, variables, data types, packages, getting help — zero to running code.

13 chapters • Beginner

No prerequisites. Start here.

What’s inside

13 chapters, from the book’s table of contents

  • Introduction to R
  • Install R & RStudio
  • Variables in R
  • Data Types in R
  • Getting Help in R
  • Vectors in R
  • Dataframes in R
  • Factors in R
  • Lists in R
  • Install & Update R Packages
  • RStudio Projects & Data Import
  • Your First Visualization
  • Your First Data Wrangling
Data Wrangling with R — Rsquared Academy R Series, Core Track 02
CORE 02

Data Wrangling with R

Import flat files and Excel, reshape with tidyr, clean with dplyr, pipes, tibbles, stringr, lubridate, forcats.

13 chapters • Beginner → Intermediate

Prereq: Core 01 Introduction to R.

What’s inside

13 chapters, plus solutions and 3 appendices

  • Import Data — Basics
  • Import Data — Advanced
  • Pipe Operator
  • dplyr Basics
  • Joining Tables using dplyr
  • dplyr Helpers
  • tibbles
  • Tidying Data with tidyr
  • Hacking Strings
  • Date & Time: Parsing and Components
  • Date & Time: Arithmetic and Time Zones
  • Categorical Data Fundamentals
  • Factor Manipulation with forcats

Also: Exercise Solutions · Appendix A Arrow, Parquet and DuckDB · B Legacy magrittr Operators · C From pandas to dplyr

Data Visualization with ggplot2 — Rsquared Academy R Series, Core Track 03
CORE 03

Data Visualization with ggplot2

Grammar of graphics, geoms, scales, facets, themes, position and stats tuning, publication polish.

22 chapters • Intermediate

Prereq: Core 01 + Core 02.

What’s inside

22 chapters, plus a recipe cheat sheet

  • Quick Tour
  • Geoms
  • Aesthetics
  • Labels
  • Text Annotations
  • Scatter Plots
  • Line Graphs
  • Bar Plots
  • Box Plots
  • Histograms
  • Modify Axis
  • Modify Legend
  • Legend: Color and Fill
  • Legend: Shape Size and Alpha
  • Faceting
  • Themes
  • Position & Stats Tuning
  • Scales, Formatting & Color Accessibility
  • Data Reshaping for ggplot2
  • Label Polishing & Wrapping
  • Finale: Publication Polish with patchwork, ggrepel & ggtext
  • Export & Communicate

Also: chapter 23 Modern Recipe Cheat Sheet.

R, Databases and SQL — Rsquared Academy R Series, Core Track 04
CORE 04

R, Databases & SQL

Connect R to databases with DBI, translate dplyr into SQL, write joins and production-grade queries.

5 chapters • Intermediate

Prereq: Core 02. Already querying in SQL? take 04 right after 02.

What’s inside

5 chapters, plus a cheat sheet and 2 appendices

  • DBI
  • dbplyr
  • SQL Basics
  • SQL Advanced
  • JOINs

Also: chapter 6 DBI Cheat Sheet · Appendix A Production R Patterns · B DuckDB + Parquet.

Command Line Basics — Rsquared Academy Companion A
COMPANION A

Command Line Basics

Files, permissions, pipes and scripting — enough shell for R users. Windows path: RStudio Terminal, Git Bash or WSL.

12 chapters • Beginner

No prerequisites. Take alongside Core 01.

What’s inside

12 chapters, plus a shell cheat sheet and a Git primer

  • Introduction
  • Navigating File System
  • File Management
  • Input/Output
  • Search & Regular Expression
  • Data Transfer
  • sudo
  • File Compression
  • System Info
  • R & the Shell
  • Pipes & Redirection
  • Conclusion

Also: chapter 13 Shell ↔ R Cheat Sheet · chapter 14 Git in 10 Minutes for RStudio Users.

Data Visualization with Base R — Rsquared Academy Companion B
COMPANION B

Data Visualization with Base R

The base graphics engine: parameters, multi-panel layouts and production export. Zero dependencies.

12 chapters • Intermediate

After Core 03 if you need fine-grained canvas control. Requires R 4.1+.

What’s inside

12 chapters, plus a Rosetta Stone appendix

  • Why Base R Graphics in 2026?
  • Introduction
  • Title & Axis Labels
  • Scatter Plots
  • Line Graphs
  • Bar Plots
  • Box Plots
  • Histograms
  • Legends
  • Text Annotations
  • Faceting
  • Production Export & Graphical Devices

Also: Appendix A Base R ↔ ggplot2 — a Rosetta Stone · References.

Shelf view — series at a glance

Introduction to R cover thumbnail, track 01
01 Intro
Data Wrangling with R cover thumbnail, track 02
02 Wrangle
Data Visualization with ggplot2 cover thumbnail, track 03
03 ggplot2
R, Databases and SQL cover thumbnail, track 04
04 SQL
Command Line Basics cover thumbnail, companion A
C-A Bash
Data Visualization with Base R cover thumbnail, companion B
C-B Base
Aravind Hebbali
AH

About the author

Aravind Hebbali — R developer, educator, founder of Rsquared Academy (Bengaluru). Post-grad, Madras School of Economics. Author of six open-access textbooks plus R packages (olsrr, blorr, inferr, descriptr, vistributions) and courses at Rsquared Academy. These books compile years of teaching + blog writing with fully reproducible examples.

aravindhebbali.com →   Rsquared Academy →   GitHub →

License & feedback. All six books are open educational resources under CC BY-NC-SA 4.0 — free to read online and to share with attribution, non-commercially. Every title also offers a verified PDF and ePub download, linked from its card. Found a typo? Open an issue on the book’s GitHub repository or write to books@rsquaredacademy.com.