Homelessness in America
Photo credit: nkbimages vis Getty Images
Contributed by Jake Lehrhoff. Jake took NYC Data Science Academy 12 week full time Data Science Bootcamp program between Sept 23 to Dec 18, 2015. The post was based on his first class project (due the 2nd week of the program).
Our world is filled with that which we choose to not see, from the rat population in New York to iTunes user agreements, all for the benefit of streamlining our own existence. A far less insubstantial marginalized aspect of society is the homeless, a population comprised of the young and old, parents and children, veterans, the mentally ill, and the unlucky.
Startlingly, estimates of mental illness in the homeless population are as high as 33%, the vast majority of which are untreated.
- Investigate state homeless populations
- Analyze the link between temperature and homeless populations
- Probe the relationship between mental health spending and homeless populations
- 2009 Annual Homeless Assessment Report (AHAR) to Congress
- 2013 Annual Homeless Assessment Report (AHAR) to Congress
- National Alliance on Mental Health (NAMH) -- State Mental Health Cuts: The Continuing Crisis
- Average winter temperature by state
Setup and Cleaning Homeless and Mental Health Data
This AHAR and NAMH data were pulled from pdf files and converted to csv using Tabula. While this simplified extraction, the resulting data frames required much cleaning. Extra spaces, commas, and symbols had to be removed before tables could be manipulated or joined.
To simplify this process, I created a function that removes symbols from text. The function takes the character to be removed as a argument, so it can be applied to data with any unwanted character.
Additionally, using dplyr, columns were renamed, others were created, and only those relevant to the project were retained. One final piece of code removes unnecessary spaces at the end of state names. This is necessary as other tables will be joined on state names in the future, making uniformity a necessity. As we had yet to cover regular expressions in the class, more sophisticated tools for cleaning text were not applied.
A similar process was repeated for the 2013 homeless data and the mental health data, as they were all scraped with Tabula. Once cleaned, mental health data was combined with the homeless data into a single dataframe.
Weather and Map Data
The weather data was also, unsurprisingly, messy. After cleaning, a new variable was created, Wtemp, cutting the data into three parts, "cold," "moderate," and "hot" winter temperatures. Finally, the data could be merged with map data for the upcoming visualizations.
There is a lot to be discovered in homelessness data, from an understanding of where the largest populations are located to possible interactions between changing mental health budgets and changing homelessness rates.
Homelessness by State
To begin the investigation, I looked at the homeless population by state by creating a choropleth map. Without controlling for population, California would stand out as bright red, with few other states earning more than a pinkish hue. Simply stated, California's homeless population is utterly massive, over 130,000 people. A graph of homeless rate is much more effective, as it takes into account California's massive population. A look at the homeless rate by state paints a different story. California may still have a high homeless population, but it is Nevada that is the most troublesome.
Next, let's consider how the homeless rate changed from 2009 to 2013. There are reasons to expect homeless rates to drop from 2009 to 2013: the country had time to recover from “The Great Recession” and unemployment dropped significantly. Many states see minor improvements in homeless rates, Nevada in particular. North Dakota, New York, Wyoming, and Montana show the opposite trend, with homeless rates rising .1-.2 percentage points.
The unsheltered homeless population is the number of people sleeping on the streets on a given night, and is, at best, an estimate. However, some states saw significant shifts in the percentage of the homeless population that went unsheltered, with North Dakota’s unsheltered rate rising a troubling 60 percentage points. This aligns with reports of surging rent in light of bubbling populations, as people flood into North Dakota looking to work in the growing oil industry. Conversely, Louisiana’s unsheltered population dropped by over 20 percentage points, as more years separated the healing city from the devastation of Hurricane Katrina.
Weather and Homelessness
It comes as no surprise that there are more homeless people in warmer climates. However, more interesting than the homeless population is the homelessness rate. This data can be visualized multiple ways. On the left, we have a boxplot showing the homeless rate by temperature group. As expected, warmer states have higher homeless rates while cold states have the lowest. When plotting homeless population instead of rates, New York appears as an outlier for cold states and California for warm states--more evidence that normalizing for population is an absolute necessity.
The density plot on the right depicts that cold and moderate temperature states have similar distributions of homeless rates, while warm states have a greater distribution of rates. New York and Alaska stick out as having discernibly higher homeless rates than other cold weather states, skewing the distribution to the right.
State Mental Health Budgets
Given the prevalence of mental illness in the homeless population, homeless rates were plotted against mental health spending, with linear regression lines included for reference. The plot above highlights a few states whose homeless rates are particularly interesting, given their mental health budgets. Of course, there are far more elements affecting homeless rates than a state's mental health budget, but it is interesting to see that Nevada has both one of the lowest budgets and one of the highest homeless rates, while Connecticut, on the other hand, has the second highest budget and one of the lowest rates. Furthermore, New York invests heavily in mental health but still hold the second highest homeless rate. Statistical analyses are necessary to understand the strength of these relationships, but such correlations are beyond the purview of this study.
Changes in Mental Health Spending
Changes in mental health spending and homeless rates from 2009 to 2013 show modest changes in homeless rates. Despite huge increases in menthal health spending, North Dakota's homeless rates continue to rise. Nevada, on the other hand, decreased it's spending and yet saw a reduction in homeless rates. Unfortunately, more current data show that that trend didn't last. Louisiana also saw a decrease in homeless rates with virtually no budgetary change, again, likely due to other services aimed to support those affected by Hurricane Katrina.
Beyond the expected relationship between temperature and homeless rates, this investigation uncovered some interesting relationships between state mental health budgets and homeless rates. For one, North Dakota's significant increase in mental health budget may be better understood in light of the increase in homeless rates, and in particular, unsheltered homeless rates. Nevada's decrease in mental health spending, possibly in light of it's decreasing homeless populations, may have set the scene for the subsequent increase in homelessness in the years following this data. Finally, the decrease in homelessness in Louisiana is due to improvements in other welfare supports beyond mental health care.
For more on mental illness and homelessness, these worthy organizations have lots of great information and prominently placed donate buttons, if you feel so inclined.