Roland KesziArtificial Intelligence &
Data Science Portfolio

On these pages I share the results of some of my data science and artificial intelligence based analysis projects.

Pages for higher education ↗

← All projects

The COVID-19 shock in the US labour market

An automated R pipeline retrieves official labour statistics from the US Bureau of Labor Statistics, then measures how deep the pandemic shock went and how long the recovery took.

Data
BLS Public Data API, monthly series, Jan 2015 – Sep 2026
Methods
REST API retrieval, tidy time series, recovery analysis
Tools
R (httr, dplyr, ggplot2)

The question

The pandemic hit the US labour market faster than any previous recession. How many jobs disappeared, how high did unemployment climb, and how long did it take to get back to where things stood in February 2020?

Approach

An R script calls the BLS Public Data API and requests three monthly, seasonally adjusted series:

The API caps the span of a single request, so the script splits the period into 10-year windows. It uses the higher-limit v2 API when a key is present and falls back to v1 without one. The key is read from an environment variable, never from the code. The tidy result is written to a CSV, so every figure can be checked without calling the API again.

Results

Unemployment rate, employment-population ratio and nonfarm payrolls, 2015 to 2026
All three indicators collapse in spring 2020. The shaded band marks the NBER recession, February–April 2020.
IndicatorFeb 2020Apr 2020ChangeBack to pre-COVID level
Unemployment rate3.5%14.8%+11.3 ppMay 2022
Employment–population ratio61.1%51.2%−9.9 ppNot fully (59.2% in Sep 2026)
Nonfarm payrolls152.3 M130.4 M−21.9 M jobsJune 2022, after 28 months

Conclusions

→ R code and data on GitHub

Data: US Bureau of Labor Statistics, Public Data API. Recession dates: NBER.