This repo shows you how to compute railroad density for every Indian subdistrict and make a cool map using R and ggplot2
In this repo, we'll explore India's railway density on a more granular level. Using the 2019 official subdistrict boundary data generously provided by superb GIS specialist Justin Elliot Meyers on his rich GitHub page as well as Geofabrik OpenStreetMap data for India, we'll learn how to effortlessly compute the length of railways and land area size for every Indian subdistrict polygon to arrive at railway density, measured as 1 kilometer of railway per 100 square kilometers of land area. We'll then plot all this on a neat choropleth map. And we'll do it programatically in R using <150 lines of code.