> ## Content Index
> Fetch the complete content index at: https://www.bambooweekly.com/llms.txt
> Use this file to discover other available public pages before exploring further.

# Bamboo Weekly #86: FEMA
- URL: https://www.bambooweekly.com/bw-86-fema/
- Published: 2024-10-02T15:00:05.000Z
- Updated: 2026-10-03T06:00:08.000Z
- Description: Get better at: Working with dates and times, pivot tables, strings, and joins
- Author: Reuven M. Lerner
- Tags: datetime, pivot-table, strings, joins

Hurricane Helene ([https://en.wikipedia.org/wiki/Hurricane\_Helene](https://en.wikipedia.org/wiki/Hurricane%5FHelene?ref=bambooweekly.com)) caused massive of damage when it passed through the Southeastern United States in the last week, including massive flooding in parts of North Carolina. Hurricanes are large and deadly, and it's thus no surprise that President Joe Biden was in touch with the governors of several affected states to ensure that they got aid – including from FEMA, the Federal Emergency Management Agency ([https://fema.gov](https://fema.gov/?ref=bambooweekly.com)). 

The White House said yesterday that they had provided a great deal of food and water to people affected by Helene, as well as search-and-rescue teams and satellite-based Internet routers. How many disasters does FEMA deal with in a given year? Have those numbers changed over time? And where do they take place?

This week, we'll look at FEMA's history of disaster aid in the United States, analyzing data describing their work over the last few decades. It would seem that they've done a remarkable job over the years of helping people to get through a wide variety of problems that would overwhelm just about anyone.

### Data and six questions

FEMA, like all US government agencies, publishes a great deal of data about its work. We can get a list of disasters on which it has worked, classified by type, date, and location (but not budget), from

[https://www.fema.gov/openfema-data-page/disaster-declarations-summaries-v2](https://www.fema.gov/openfema-data-page/disaster-declarations-summaries-v2?ref=bambooweekly.com)

FEMA provides an API to query and download this data, but it also makes the raw data available in a variety of formats. Much to my pleasant surprise, this includes Parquet, a binary format used by the Apache Arrow project ([https://arrow.apache.org/](https://arrow.apache.org/?ref=bambooweekly.com)). You can find the Parquet file (along with other formats) in the "Full data" section of the data page. You can download FEMA's Parquet file itself from:

[https://www.fema.gov/api/open/v2/DisasterDeclarationsSummaries.parquet](https://www.fema.gov/api/open/v2/DisasterDeclarationsSummaries.parquet?ref=bambooweekly.com)

We'll also use some data classified by FEMA regions. Information about those regions is at:

[https://www.fema.gov/about/organization/regions](https://www.fema.gov/about/organization/regions?ref=bambooweekly.com)

This week, I have six tasks and questions for you. Among the learning goals are working with datetime data, pivot tables, plotting, working with string data, and performing joins. As usual, I'll be back tomorrow with my complete solutions, including a downloadable version of the Jupyter notebook I used to solve these problems.

Here are my questions for this week:

- Create a data frame from the Parquet file. Make sure that all of the columns describing dates have a `dtype` of `datetime`.
- Create a bar graph showing the number of disasters that FEMA has handled in each year, starting in 2000\. (Use the `incidentBeginDate` as the source of the year.) The bar should be subdivided into colored sections indicating the types of disasters. Only include the 5 most common disaster types. Does any year stand out? How different do things look if we count every entry in the data set as a separate disaster, vs. every unique `disasterNumber`?
- Create a histogram showing how frequently each FEMA disaster is declared, only counting each `disasterNumber` a single time. Are any months more (or less) likely to have disasters?
- We see that a single disaster number can be associated with a number of rows in the data set. By how much does that vary? What can we learn by comparing the mean and median?
- Which 10 states have had the greatest number of disasters (counting each record, not just each disaster number) starting in 2000?
- FEMA divides the United States into 10 regions. Plot a bar graph showing the number of total disasters per region, starting in 2000, counting each disaster ID only once. The x axis should show a comma-separated list of states for each region, as found on the region-information page.

I'll be back tomorrow with my solutions.

Reuven