Skip to content

[PULL REQUEST] Updating mortality scripts#155

Open
KPHSANDAG wants to merge 7 commits into
mainfrom
154-revising-mortality
Open

[PULL REQUEST] Updating mortality scripts#155
KPHSANDAG wants to merge 7 commits into
mainfrom
154-revising-mortality

Conversation

@KPHSANDAG

Copy link
Copy Markdown
Contributor

Describe this pull request. What changes are being made?

This pr changes the source of mortality data from the data folders data/deaths and data/undesa to the socioec_data warehouse containing [vital_statistics].[cdc_wonder_mortality] and [vital_statistics].[undesa_survivors]. Existing scripts in death_rates.py have been modified to account for the source change and new sql files calling the data have been added.

Lastly, the streamlit file 3_Rates.py has been modified to fit the line length and to assure sorting for the mortality files to prevent issues in visualizations.

Validation and testing

Successful run can be seen in [CohortComponentModel].[outputs].[rates] or in the streamlit report where run_id = 57.

What issues does this pull request address?

closes #154

Additional context

N/A

@KPHSANDAG KPHSANDAG self-assigned this Jul 10, 2026
@KPHSANDAG KPHSANDAG added the enhancement New feature or request label Jul 10, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review this pull request because it exceeds the maximum number of files (300). Try reducing the number of changed files and requesting a review from Copilot again.

@GregorSchroeder GregorSchroeder left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have the data nicely stored in [socioec_data] so let's take advantage of that and do more data processing in SQL server and simplify the Python code.

Comment thread sql/undesa_survivors.sql Outdated
Comment thread sql/cdc_wonder_mortality.sql Outdated
Comment thread python/input_modules/death_rates.py Fixed
Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE] Change source for mortality to SQL

3 participants