UI-Research / mobility-from-poverty

https://ui-research.github.io/mobility-from-poverty/
5 stars 1 forks source link

Iss223 -- deaths from injury #271

Closed vpancini closed 6 months ago

vpancini commented 7 months ago

This metric brings in age-adjusted mortality rates for injury deaths from CDC WONDER for 2014-2020. Only crude rates are currently available for the most recent year, 2021, so we do not pull data for that year. We used data from County Health Rankings last year for this metric (their source data was also from CDC WONDER). However, they reported crude rates so our numbers do not match. The rates are already calculated by CDC WONDER, so the program mostly focuses on adding data quality flags and validation.

The only outstanding problem area is that we don't have counts for Chugach Census Area, AK and Copper River Census Area, AK for 2020. These census areas were created from Valdez-Cordova Census Area, AK in 2019. I wasn't sure if there was an existing way to crosswalk this. It is flagged in the code.

vpancini commented 7 months ago

Data used for this metric are available on Box

vpancini commented 6 months ago

I have addressed all reviewer comments and pushed the updated files.

wcurrangroome commented 6 months ago
vpancini commented 6 months ago
  • There's one chunk with a testthat assertion that isn't fully built out (maybe it still works as-is?). If you search for "Check that these observations are equal" you should find it; the full code block might look like: testthat::expect_equal( not_missing$rate_injury_death_chr, not_missing$rate_injury_death_crude)
  • At "4.3 Identify counties in CDC Wonder but not in Urban universe": I'm seeing 36 observations, but the text refers to 50. Can you double-check this? I'm running things interactively, so I might be getting a different number because I've changed a variable relative to the value it would have at this point in the execution of the script (though I don't think that's the issue).
  • Per discussion, address the two AK census areas.
  • Then, run one last time top-to-bottom and this should be good to go!