Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions statvar_imports/us_cdc/single_race/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ To obtain the raw input files, data must be manually downloaded from the source.
*Single Race (6 categories)
*ICD-10-113 Cause List

For each download, a specific state must be selected. The desired year range is from 2018 to 2023. After making the selections, click the "Send" button at the bottom to initiate the download.
For each download, a specific state must be selected. After making the selections, click the "Send" button at the bottom to initiate the download.


### Data Processing
Expand All @@ -38,7 +38,7 @@ After the files are downloaded, the data is processed using the stat_var_process

```bash

python3 ../../../tools/statvar_importer/stat_var_processor.py --existing_statvar_mcf=gs://unresolved_mcf/scripts/statvar/stat_vars.mcf --input_data=input_files/*.csv --pv_map=single_race_pvmap.csv --config_file=single_race_metadata.csv --output_path=output/underlyingcauseofdeath2018_2023singlerace
python3 ../../../tools/statvar_importer/stat_var_processor.py --existing_statvar_mcf=gs://unresolved_mcf/scripts/statvar/stat_vars.mcf --input_data=input_files/*.csv --pv_map=single_race_pvmap.csv --config_file=single_race_metadata.csv --output_path=output/underlyingcauseofdeath_singlerace --output_counters=counters/underlyingcauseofdeath_singlerace.csv
```

### Automation
Expand Down
11 changes: 7 additions & 4 deletions statvar_imports/us_cdc/single_race/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,19 @@
"provenance_description": "Mortality statistics, categorized by demographic factors and specific causes of death, location, race at state level.",
"scripts": [
"download.sh",
"../../../tools/statvar_importer/stat_var_processor.py --existing_statvar_mcf=gs://unresolved_mcf/scripts/statvar/stat_vars.mcf --input_data=input_files/*.csv --pv_map=single_race_pvmap.csv --config_file=single_race_metadata.csv --output_path=output/underlyingcauseofdeath2018_2023singlerace"
"../../../tools/statvar_importer/stat_var_processor.py --existing_statvar_mcf=gs://unresolved_mcf/scripts/statvar/stat_vars.mcf --input_data=input_files/*.csv --pv_map=single_race_pvmap.csv --config_file=single_race_metadata.csv --output_path=output/underlyingcauseofdeath_singlerace --output_counters=counters/underlyingcauseofdeath_singlerace.csv"
],
"import_inputs": [
{
"template_mcf": "output/underlyingcauseofdeath2018_2023singlerace.tmcf",
"cleaned_csv": "output/underlyingcauseofdeath2018_2023singlerace.csv"
"template_mcf": "output/underlyingcauseofdeath_singlerace.tmcf",
"node_mcf": "output/underlyingcauseofdeath_singlerace_stat_vars.mcf",
"cleaned_csv": "output/underlyingcauseofdeath_singlerace.csv"
}
],
"validation_config_file": "validation_config.json",
"source_files": [
"input_files/*.csv"
"input_files/*.csv",
"counters/*.csv"
],
"cron_schedule": "30 08 8-14 * 6"
}
Expand Down
6 changes: 4 additions & 2 deletions statvar_imports/us_cdc/single_race/single_race_metadata.csv
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ url,https://wonder.cdc.gov/controller/datarequest/D158
description,"Mortality statistics, categorized by demographic factors and specific causes of death, location, race at state level"
#place_type,state level
#places_within,
start_date,2018
end_date,2023
#start_date,2018
#end_date,2024
release_frequency,P1Y
process,
comments,
Expand All @@ -13,3 +13,5 @@ mapped_rows,1
mapped_columns,11
header_rows,1
debug,0
output_only_new_statvars,False