HStern
  • Blog
  • Tools
  • Notes
  • Research
  • About
Pirating the Book of Kells (like a viking)
webscraping
The Book of Kells is an extraordinary 9th century gospel book and also the subject of a pretty good animated movie.
Nov 24, 2025
Robust relative paths
programming
python
By now, most data scientists have learnt not to use absolute paths in their replication packages, and for good reason: absolute paths guarantee that the code will not run on…
Apr 19, 2025
Excel’s lambda function is misnamed
programming
eccentricity
I don’t like Excel, but I can acknowledge that it has gotten a lot better over the last five years. One of my favourite new features is the lambda function that was added in…
Mar 29, 2025
Misleading productivity charts
econ
Comparing productivity between countries is difficult. Variations in the systems of national accounts, data availability, and purchasing power must all be considered and…
Feb 9, 2025
Peanuts for working
eccentricity
I eat peanuts for lunch every day and am often called upon to defend this practice. Although the reasons are, to me, completely obvious, I have not yet been able to convince…
Jan 26, 2025
An easier way to generate seaborn ridgeplots
python
While their Joy Division inspired t-shirts and posters have given some people the impression that they’re not a serious visualization tool, ridgeline plots are an effective…
Jun 1, 2024
Computing producer surplus from a parametric supply curve
econ
This is problem 12.5 from Nicholson and Snyder (2017). The textbook solution used a linear approximation but it is actually a good example of a parametric integral. Since…
Mar 28, 2024
Valid inputs in multiple keyboard layouts
typing
python
Most of the time, inputting keys in the wrong keyboard layout will result in gibberish — but not always. I thought today I would try to find the longest input sequences that…
Mar 5, 2024
Following New Economics Papers with RSS
econ
webscraping
The option to subscribe to REPEC’s NEP service is hidden but still available. This post provides a list of available rss feeds.
Oct 4, 2023
Predoc Data Task: Labor Market Analysis
rlang
econ
Here is my solution to the sample labour market analysis task published by PreDoc.org.
Sep 28, 2023
Predoc Data Task: Data Manipulation
rlang
This is my solution to the sample data manipulation task published by PreDoc.org.
Sep 28, 2023
Examining the Score Distributions of the GRE and GMAT
stats
school
It’s somewhat strange that GRE and GMAT score percentiles are almost always presented in table form rather than visualizations. Plotting makes the distributions much easier…
Jul 11, 2023
How Fast Did Barbara Blackburn Type on Letterman?
typing
python
In 1985 Barbara Blackburn appeared on Late Night with David Letterman in one of the most disastrous late night segments of all time.
Jul 1, 2023
Integrating R Graphics with Neovim and Nvim-R
nvim
rlang
config
The Nvim-R plugin extends a lot of RStudio functionality to Neovim but the default plotting experience leaves a lot to be desired.
Jun 25, 2023
Infinite Fizzbuzz With Generator Functions
compsci
ojs
Anyone can write a solution to the FizzBuzz problem, but what if you need it to run indefinitely?
Jun 8, 2023
Understanding the FHSA
finance
tax
allocation
The FHSA does not combine the benefits of the TFSA and RRSP. It has unique advantages that make it completely different from any other registered account.
Apr 20, 2023
No matching items