// the find
jtleek/capitalIn21stCenturyinR
Piketty in R
A collection of R Markdown documents that reproduce the charts and tables from the technical appendix of Piketty's Capital in the 21st Century, organized chapter by chapter. It's aimed at economics students or R users who want to see the data and code behind the book's figures rather than just read the conclusions.
- Each chapter is a self-contained R Markdown file paired with its rendered HTML, so you can see code, output, and commentary together without re-running anything
- Uses caching (knitr cache directories per table) so repeated builds of the heavier chapters don't redo expensive computation
- Mirrors the book's own chapter and figure numbering closely, making it easy to cross-reference a specific claim in the text against the exact code that produced it
- Dead since 2016 — no updates for R, dplyr/ggplot2 API changes, or broken CRAN dependencies, so a decent chunk of the .Rmd files likely won't knit on a current R install without fixing
- No single entry point or index; you have to dig through chapter folders to find anything, and there's no top-level script that runs the whole analysis end to end
- Repo is bloated with committed binary artifacts (rendered .html, .pdf figures, .RData/.rdb/.rdx cache files, .xlsx tables) instead of just the source and a build step, which makes it slow to clone and hard to diff
- No tests, no CI, and no license file, so reuse or redistribution of the code is legally murky