Synopsis

This analysis explores the U.S. National Oceanic and Atmospheric Administration’s (NOAA) storm database to determine which types of severe weather events are most harmful to population health and have the greatest economic consequences. The data covers weather events from 1950 to November 2011, with more recent years being more complete. After processing and cleaning the data, we analyzed fatalities and injuries to assess impact on population health, and property and crop damage to assess economic consequences. Our findings show that tornadoes are by far the most harmful event type to population health, causing the most fatalities and injuries. For economic consequences, floods cause the most property damage while droughts cause the most crop damage, with floods having the greatest overall economic impact when combining property and crop damage. These results can help government and municipal managers prioritize resources for severe weather preparedness.

Data Processing

Loading Required Libraries

{r, message=FALSE} library(dplyr) library(ggplot2) library(tidyr)

Loading the Data

The data was loaded directly from the compressed CSV file provided by NOAA.

# Download and load the data
if (!file.exists("repdata_data_StormData.csv.bz2")) {
  download.file("https://d396qusza40orc.cloudfront.net/repdata%2Fdata%2FStormData.csv.bz2", 
                "repdata_data_StormData.csv.bz2", method = "curl")
}

storm_data <- read.csv("repdata_data_StormData.csv.bz2")

Examining the Data

# Check the structure and dimensions of the data
dim(storm_data)
names(storm_data)

Data Processing and Cleaning

We need to process the data to extract relevant information for our analysis, particularly focusing on:

  1. Event types (EVTYPE)
  2. Health impact (fatalities and injuries)
  3. Economic impact (property and crop damage)
# Select relevant columns for analysis
relevant_cols <- c("EVTYPE", "FATALITIES", "INJURIES", "PROPDMG", "PROPDMGEXP", 
                   "CROPDMG", "CROPDMGEXP")

storm_clean <- storm_data[, relevant_cols]

# Convert event type to consistent case for grouping
storm_clean$EVTYPE <- toupper(storm_clean$EVTYPE)

# Process damage exponents to create numeric multipliers
convert_exponent <- function(exp) {
  exp <- toupper(exp)
  ifelse(exp == "K", 1000,
         ifelse(exp == "M", 1000000,
                ifelse(exp == "B", 1000000000, 1)))
}

storm_clean$PROPDMGEXP <- convert_exponent(storm_clean$PROPDMGEXP)
storm_clean$CROPDMGEXP <- convert_exponent(storm_clean$CROPDMGEXP)

# Calculate actual damage values
storm_clean$PROPDMG_VAL <- storm_clean$PROPDMG * storm_clean$PROPDMGEXP
storm_clean$CROPDMG_VAL <- storm_clean$CROPDMG * storm_clean$CROPDMGEXP

Aggregating Data for Analysis

We’ll aggregate the data by event type to analyze total impact.

# Aggregate by event type
health_impact <- storm_clean %>%
  group_by(EVTYPE) %>%
  summarise(
    Total_Fatalities = sum(FATALITIES, na.rm = TRUE),
    Total_Injuries = sum(INJURIES, na.rm = TRUE),
    Total_Health_Impact = Total_Fatalities + Total_Injuries
  ) %>%
  arrange(desc(Total_Health_Impact))

economic_impact <- storm_clean %>%
  group_by(EVTYPE) %>%
  summarise(
    Total_Property_Damage = sum(PROPDMG_VAL, na.rm = TRUE),
    Total_Crop_Damage = sum(CROPDMG_VAL, na.rm = TRUE),
    Total_Economic_Impact = Total_Property_Damage + Total_Crop_Damage
  ) %>%
  arrange(desc(Total_Economic_Impact))

Results

Most Harmful Events to Population Health

After processing the data, we can identify which event types cause the most harm to population health.

# Get top 10 events for health impact
top_health <- head(health_impact, 10)

# Create a plot for health impact
health_long <- top_health %>%
  select(EVTYPE, Total_Fatalities, Total_Injuries) %>%
  pivot_longer(cols = c(Total_Fatalities, Total_Injuries), 
               names_to = "Impact_Type", values_to = "Count")

ggplot(health_long, aes(x = reorder(EVTYPE, -Count), y = Count, fill = Impact_Type)) +
  geom_bar(stat = "identity", position = "dodge") +
  theme(axis.text.x = element_text(angle = 45, hjust = 1)) +
  labs(title = "Top 10 Most Harmful Weather Events to Population Health",
       x = "Event Type", y = "Count", fill = "Impact Type") +
  scale_fill_manual(values = c("Total_Fatalities" = "red", "Total_Injuries" = "orange"))

Figure 1: Top 10 Most Harmful Weather Events to Population Health - This figure shows the events causing the most fatalities (red) and injuries (orange). Tornadoes are clearly the most harmful event type, causing significantly more injuries than any other event.

Based on our analysis, tornadoes are by far the most harmful weather event to population health, causing both the most fatalities and injuries. The top 5 most harmful event types for population health are:

  1. Tornado
  2. Excessive Heat
  3. Thunderstorm Wind
  4. Flood
  5. Lightning

Events with Greatest Economic Consequences

Now let’s examine which events have the greatest economic consequences.

# Get top 10 events for economic impact
top_economic <- head(economic_impact, 10)

# Create a plot for economic impact
economic_long <- top_economic %>%
  select(EVTYPE, Total_Property_Damage, Total_Crop_Damage) %>%
  pivot_longer(cols = c(Total_Property_Damage, Total_Crop_Damage), 
               names_to = "Damage_Type", values_to = "Amount")

# Convert to billions for better readability
economic_long$Amount_Billions <- economic_long$Amount / 1e9

ggplot(economic_long, aes(x = reorder(EVTYPE, -Amount_Billions), y = Amount_Billions, fill = Damage_Type)) +
  geom_bar(stat = "identity", position = "stack") +
  theme(axis.text.x = element_text(angle = 45, hjust = 1)) +
  labs(title = "Top 10 Weather Events with Greatest Economic Consequences",
       x = "Event Type", y = "Damage (Billions of USD)", fill = "Damage Type") +
  scale_fill_manual(values = c("Total_Property_Damage" = "blue", "Total_Crop_Damage" = "green"))

Figure 2: Top 10 Weather Events with Greatest Economic Consequences - This figure shows property damage (blue) and crop damage (green) in billions of USD. Floods cause the most property damage, while droughts cause the most crop damage.

Our analysis shows that floods have the greatest economic consequences overall, primarily due to extensive property damage. The top 5 events with the greatest economic impact are:

  1. Flood
  2. Hurricane/Typhoon
  3. Tornado
  4. Storm Surge
  5. Drought

It’s worth noting that while droughts rank 5th in overall economic impact, they cause the most crop damage of any event type. Similarly, hurricanes/typhoons cause significant damage across both property and crops.

Combined Analysis

To provide a comprehensive view, let’s compare the top events for both health and economic impact.

# Create a combined dataset for comparison
top_events_health <- head(health_impact$EVTYPE, 5)
top_events_economic <- head(economic_impact$EVTYPE, 5)

# Create a summary table
summary_table <- data.frame(
  Rank = 1:5,
  Health_Impact = top_events_health,
  Economic_Impact = top_events_economic
)

print(summary_table)

This analysis provides clear guidance for resource allocation in severe weather preparedness. For protecting population health, priority should be given to tornado warning systems and response planning. For economic protection, flood control measures and drought-resistant agriculture should be prioritized.