Build a community health profile using CDC PLACES and Census ACS data. Use when asked about health indicators, disparities, community health, or social determinants in the Richmond metro area.
Follow these steps to build a complete community health profile for the Richmond metro area.
Query the CDC PLACES API for county- and city-level measures across four jurisdictions:
API endpoint: https://data.cdc.gov/resource/swc5-untb.json
Save raw JSON responses to data/raw/places_{jurisdiction}.json.
From the PLACES download, extract these six indicator categories:
Clean and reshape into a tidy DataFrame. Save to data/processed/places_measures.csv.
Using the Census ACS 5-Year API (https://api.census.gov/data/2022/acs/acs5), pull:
for all four jurisdictions plus Virginia statewide.
Save to data/processed/acs_socioeconomic.csv.
Compare each jurisdiction against:
Flag any jurisdiction where a measure is more than 2 percentage points above the state average. Frame these as opportunities for investment, not deficits.
Save comparison table to data/processed/benchmark_comparison.csv.
Build a composite health index for each jurisdiction:
Save to data/processed/composite_index.csv.
Generate three main visualizations:
Grouped bar chart showing all six PLACES measures side by side for each jurisdiction. Include Virginia and US benchmark lines. Save to figures/jurisdiction_comparison.png and figures/jurisdiction_comparison.html.
One radar chart overlaying all four jurisdictions across the six health measures. Normalize so that outward = worse health outcome. Save to figures/radar_health_profile.png.
Scatter plot with median household income on the x-axis and composite health index on the y-axis. Label each jurisdiction. Add a trend annotation if appropriate. Save to figures/health_vs_income_scatter.png.
Chart standards:
Write a 500-800 word summary to reports/community_health_narrative.md that includes:
Writing standards:
Before finalizing, verify: