Massachusetts City Population by Crime Rate (Final Project)
This scatter plot compares Massachusetts city populations and crime rates, with each circle representing a city colored by county. The visualization reveals that cities with similar population ranges, such as New Bedford and Fall River, exhibit higher burglary rates compared to peers. Built with the vega-lite-api, it uses d3.csv to load crime data from a gist, applies a logarithmic population scale, and includes tooltips for county, city, population, and crime rate details. The config.js file customizes axis styling and typography for improved readability.
AI-generated descriptionA visualization constructed using the vega-lite-api.
Crime dataset has been visualized. At similar range of population, New Bedford, fall river has higher Burglary crime
dataset intro is here
Gist is from here
Modification
Select population and crime rate to form a scatter plot, so at similar population range, we can compared city crime rate.
Colored by county with tool tip, so user can easily tell Hampden county has higher crime.