2024-03-21

Code for Average Maternal Mortality Rates by Race/Ethnicity Over the Years

agg_df <- df %>%
  group_by(year_id, race_group) %>%
  summarise(avg_val = mean(val), .groups = "drop")

plot <- plot_ly(data = agg_df, x = ~year_id, y = ~avg_val, 
  color = ~race_group, type = 'scatter', mode = 'lines+markers')

plot <- plot %>%
  layout(xaxis = list(title = "Year"),
         yaxis = list(title = "Average Maternal Mortality Rate"),
         legend = list(title = "Race/Ethnicity"),
         hovermode = "closest")

Average Maternal Mortality Rates by Race/Ethnicity Over the Years

Average Mortality Rate by Location

Average Mortality by Race and Predicted Values for 2020

Prediction Accuracy

The MMR (Maternal Mortality Ratio) is calculated by \(\frac{Number of Maternal Deaths}{Number of Live Births} * 100,000\). This results in a ratio that shows the maternal mortality per hundred thousand live births.

Prediction Comparison

Race Group Prediction 2020 Stats
All racial and ethnic groups 37.3 23.8
Hispanic and any race 21.5 18.2
Non-Hispanic American Indian and Alaska Native 57.9 32.0
Non-Hispanic Asian, Native Hawaiian, or Other Pacific Islander 24.2 12.8
Non-Hispanic Black 62.2 55.3
Non-Hispanic White 32.3 19.1

Error

Here we can see that predictions tended to over-estimate. Calculating our percent error:

Race Group Equation Error (in percent)
All racial and ethnic groups \(\frac{|37.3-23.8|}{23.8}\) 56.72
Hispanic and any race \(\frac{|21.5-18.2|}{18.2}\) 18.13
Non-Hispanic American Indian and Alaska Native \(\frac{|57.9-32.0|}{32.0}\) 80.9
Non-Hispanic Asian, Native Hawaiian, or Other Pacific Islander \(\frac{|24.2-12.8|}{12.8}\) 89.0
Non-Hispanic Black \(\frac{|62.2-55.3|}{55.3}\) 12.47
Non-Hispanic White \(\frac{|32.3-19.1|}{19.1}\) 69.1