This dashboard is a collaboration between the Pennsylvania Housing Finance Agency and the Housing Initiative at Penn, designed to visualize housing affordability trends across Pennsylvania. It showcases current housing trends in counties statewide, based on data from the U.S. Census Bureau's 5-year American Community Survey and the U.S. Department of Housing and Urban Development's Comprehensive Housing Affordability Strategy.
The dashboard utilizes the American Community Survey's 2022 5-year estimates and the HUD’s Comprehensive Housing Affordability Strategy dataset (2019) for the Affordable Housing Shortage variable. Data was accessed through the US Census Bureau API using the tidycensus
package, with processing and preparation done via dplyr
, tigris
, sf
, stringr
, and tidyr
. Visualizations are created using leaflet
, plotly
, ggplot2
, and pander
in the R-language with Posit's R-Shiny app interface.
- Homeownership rate (%) 2022
- Description: The percentage of households that own their homes. A higher rate indicates a greater proportion of homeowners in the area.
- Source: 2022 American Community Survey 5-Year Estimates, U.S. Census Bureau
- Rentership rate (%) 2022
- Description: The share of households in a county that rent their homes. Younger households and households with limited incomes are more likely to rent than older households and households with higher incomes.
- Source: 2022 American Community Survey 5-Year Estimates, U.S. Census Bureau
- Vacant rental units (%) 2022
- Description: The percentage of rental units that are currently unoccupied. A higher percentage can suggest that there's a surplus of rental housing or potentially decreased demand.
- Source: 2022 American Community Survey 5-Year Estimates, U.S. Census Bureau
- Median age of home (years) 2022
- Description: The midpoint age of homes in a specific area. Older median ages can suggest historical or older neighborhoods, while lower values might indicate newer developments.
- Source: 2022 American Community Survey 5-Year Estimates, U.S. Census Bureau
- Median home value ($) 2022
- Description: The midpoint value of homes in the area. This can provide an insight into the overall affordability and property values of a region.
- Source: 2022 American Community Survey 5-Year Estimates, U.S. Census Bureau
- Households with internet access (%) 2022
- Description: The percentage of households that have access to the internet. This can provide insights into the area's technological infrastructure and development.
- Source: 2022 American Community Survey 5-Year Estimates, U.S. Census Bureau
- Rent-burdened households (%) 2022
- Description: The percentage of extremely low-income households spending 30% or more of their income on rent. Extremely low-income households are those with annual household incomes of $35,000 or less. This does not include households who do not pay rent.
- Source: 2022 American Community Survey 5-Year Estimates, U.S. Census Bureau
- Mortgage burdened households (%) 2022
- Description: The percentage of extremely low-income households spending 30% or more of their incomes on mortgage payments. Extremely low-income households are those with annual household incomes of $35,000 or less. This does not include households who have finished paying their mortgage.
- Source: 2022 American Community Survey 5-Year Estimates, U.S. Census Bureau
- Median gross rent ($) 2022
- Description: The midpoint amount that households pay in total for their contract rent, utilities, and fuel costs. Higher median gross rent can indicate greater challenges with housing affordability for low-income households.
- Source: 2022 American Community Survey 5-Year Estimates, U.S. Census Bureau
- Affordable housing shortage (units)
- Description: The difference between the demand for rental units affordable to extremely low-income households (income < 30% of area median income) and the supply available. A positive number indicates a shortage of affordable housing units.
- Source: Comprehensive Housing Affordability Strategy (CHAS) dataset, U.S. Department of Housing and Urban Development
- Interactive map visualizations with
leaflet
- Dynamic data visualization using
plotly
- Easy csv export of filtered data
- Customizable filters for cross-county comparisons
- R Shiny,
leaflet
,plotly
,ggplot2
,pander
for development and visualization tidycensus
,dplyr
,tigris
,sf
,stringr
,tidyr
for data processing
To run this dashboard locally, you need to have R and RStudio installed on your machine. Follow these steps:
- Install R from CRAN
- Install RStudio from RStudio's website
- Open RStudio and install the required packages using the following command:
R install.packages(c("shiny", "rsconnect", "conflicted", "tidyr", "shinythemes", "bslib", "leaflet", "shinyWidgets", "plotly", "sf", "stringr", "tidyverse", "mapview"))
- Clone this repository or download the
ui.R
andserver.R
files to your local machine. - Open either
ui.R
orserver.R
in RStudio, and run the application by clicking 'Run App'.
After launching the dashboard, you can:\
- Use the map to explore housing trends across different regions in Pennsylvania.\
- Apply filters to narrow down the data by specific criteria such as time period, housing type, etc.\
- Interact with the visualizations to gain detailed insights into housing affordability.
The Pennsylvania Housing Finance Agency is dedicated to providing affordable homeownership and rental apartment options for older adults, low- and moderate-income families, and people with special housing needs. It promotes economic development across the Commonwealth through its mortgage programs, investments in multifamily housing developments, and community development projects funding.
Based in the University of Pennsylvania's Weitzman School of Design, the Housing Initiative at Penn is a housing policy research initiative. It conducts rigorous academic and empirical research to advance evidence-based policymaking and analyzes current conditions and future trends in housing, aiming for more effective and equitable housing policy at various levels.
For questions about this dashboard, please contact:
Anna Duan, Housing Research Analyst, at annaduan@sas.upenn.edu
Amy Sechrist, Senior Policy Officer, at asechrist@phfa.org
March 2024