-
Notifications
You must be signed in to change notification settings - Fork 130
Bulgaria census #1753
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
abhishekjaisw
wants to merge
19
commits into
datacommonsorg:master
Choose a base branch
from
abhishekjaisw:bulgaria_census
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+6,995
−0
Open
Bulgaria census #1753
Changes from all commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
d4d8459
bulgaria cenus data
abhishekjaisw add2e94
Merge branch 'master' into bulgaria_census
abhishekjaisw cbede45
bulgaria_nsi_demographics data updated V1
abhishekjaisw ce203a9
Merge branch 'master' into bulgaria_census
abhishekjaisw 0615e0e
Merge branch 'master' into bulgaria_census
abhishekjaisw b387e91
Merge branch 'master' into bulgaria_census
abhishekjaisw 482ccbd
Merge branch 'master' into bulgaria_census
abhishekjaisw efe34b7
bulgaria_nsi_demographics data updated V2
abhishekjaisw ffd1dd1
bulgaria_nsi_demographics data updated V4
abhishekjaisw cea35c5
Merge branch 'master' into bulgaria_census
abhishekjaisw fada95b
Cleanup: remove unnecessary data files and logs
abhishekjaisw f40d3ce
Merge branch 'master' into bulgaria_census
abhishekjaisw a81c214
Merge branch 'master' into bulgaria_census
abhishekjaisw 3e177e5
Merge branch 'master' into bulgaria_census
abhishekjaisw db02656
fixed bulgaria_nsi_demographics comments from sandeep
abhishekjaisw 00066e7
fixed bulgaria_nsi_demographics comments from sandeep
abhishekjaisw 4681de3
Cleanup: Remove duplicate folder BulgariaNSI_Demographics_old and kee…
abhishekjaisw 415d216
Merge branch 'master' of https://github.com/datacommonsorg/data into …
abhishekjaisw 05b328e
addressed comments
abhishekjaisw File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
7 changes: 7 additions & 0 deletions
7
statvar_imports/Bulgaria_NSI_Demographics/BulgariaNSI_Demographics_metadata.csv
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| parameter,value | ||
| mapped_rows,3 | ||
| word_delimiter,"""""" | ||
| mapped_columns,1 | ||
| provenance_url,https://www.nsi.bg/en/statistical-data/204/636 | ||
abhishekjaisw marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| output_columns,"observationDate,observationAbout,value,variableMeasured" | ||
| statvar_dcid_ignore_values,"-" | ||
70 changes: 70 additions & 0 deletions
70
statvar_imports/Bulgaria_NSI_Demographics/BulgariaNSI_Demographics_pvmap.csv
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,70 @@ | ||
| key,p1,v1,p2,v2,p3,v3,p4,v4,p5,v5 | ||
| "POPULATION BY DISTRICTS, AGE, PLACE OF RESIDENCE AND SEX AS OF 31.12.2024 (Number)",observationDate,2024,#Header,observationDate,,,,,, | ||
| "POPULATION BY DISTRICTS, AGE, PLACE OF RESIDENCE AND SEX AS OF 31.12.2025 (Number)",observationDate,2025,#Header,observationDate,,,,,, | ||
| "POPULATION BY DISTRICTS, AGE, PLACE OF RESIDENCE AND SEX AS OF 31.12.2026 (Number)",observationDate,2026,#Header,observationDate,,,,,, | ||
| "POPULATION BY DISTRICTS, AGE, PLACE OF RESIDENCE AND SEX AS OF 31.12.2027 (Number)",observationDate,2027,#Header,observationDate,,,,,, | ||
| "POPULATION BY DISTRICTS, AGE, PLACE OF RESIDENCE AND SEX AS OF 31.12.2028 (Number)",observationDate,2028,#Header,observationDate,,,,,, | ||
| "POPULATION BY DISTRICTS, AGE, PLACE OF RESIDENCE AND SEX AS OF 31.12.2029 (Number)",observationDate,2029,#Header,observationDate,,,,,, | ||
| "POPULATION BY DISTRICTS, AGE, PLACE OF RESIDENCE AND SEX AS OF 31.12.2030 (Number)",observationDate,2030,#Header,observationDate,,,,,, | ||
| "POPULATION BY DISTRICTS, AGE, PLACE OF RESIDENCE AND SEX AS OF 31.12.2031 (Number)",observationDate,2031,#Header,observationDate,,,,,, | ||
| "POPULATION BY DISTRICTS, AGE, PLACE OF RESIDENCE AND SEX AS OF 31.12.2032 (Number)",observationDate,2032,#Header,observationDate,,,,,, | ||
| "POPULATION BY DISTRICTS, AGE, PLACE OF RESIDENCE AND SEX AS OF 31.12.2033 (Number)",observationDate,2033,#Header,observationDate,,,,,, | ||
|
|
||
|
|
||
| ,,,,,,,,,, | ||
| Male,gender,Male,value,{Number},measuredProperty,count,populationType,Person,, | ||
| Female,gender,Female,value,{Number},measuredProperty,count,populationType,Person,, | ||
| Urban residence,placeOfResidenceClassification,Urban,value,{Number},measuredProperty,count,populationType,Person,, | ||
| Rural residence,placeOfResidenceClassification,Rural,value,{Number},measuredProperty,count,populationType,Person,, | ||
| Total:Total,gender,'',value,{Number},measuredProperty,count,populationType,Person,, | ||
| 0,age,[0 Years],,,,,,,, | ||
| 1 - 4,age,[1 4 Years],,,,,,,, | ||
| 5 - 9,age,[5 9 Years],,,,,,,, | ||
| 10 - 14,age,[10 14 Years],,,,,,,, | ||
| 15 - 19,age,[15 19 Years],,,,,,,, | ||
| 20 - 24,age,[20 24 Years],,,,,,,, | ||
| 25 - 29,age,[25 29 Years],,,,,,,, | ||
| 30 - 34,age,[30 34 Years],,,,,,,, | ||
| 35 - 39,age,[35 39 Years],,,,,,,, | ||
| 40 - 44,age,[40 44 Years],,,,,,,, | ||
| 45 - 49,age,[45 49 Years],,,,,,,, | ||
| 50 - 54,age,[50 54 Years],,,,,,,, | ||
| 55 - 59,age,[55 59 Years],,,,,,,, | ||
| 60 - 64,age,[60 64 Years],,,,,,,, | ||
| 65 - 69,age,[65 69 Years],,,,,,,, | ||
| 70 - 74,age,[70 74 Years],,,,,,,, | ||
| 75 - 79,age,[75 79 Years],,,,,,,, | ||
| 80 - 84,age,[80 84 Years],,,,,,,, | ||
| 85 - 89,age,[85 89 Years],,,,,,,, | ||
| 90 - 94,age,[90 94 Years],,,,,,,, | ||
| 95 - 99,age,[95 99 Years],,,,,,,, | ||
| 100 +,age,[100 - Years],,,,,,,, | ||
| Districts Age (years),observationAbout,country/BGR,#Header,observationAbout,,,,,, | ||
| Blagoevgrad,observationAbout,wikidataId/Q173277,#Header,observationAbout,,,,,, | ||
| Burgas,observationAbout,wikidataId/Q6509,#Header,observationAbout,,,,,, | ||
| Varna,observationAbout,wikidataId/Q6506,#Header,observationAbout,,,,,, | ||
| Veliko Tarnovo,observationAbout,wikidataId/Q173474,#Header,observationAbout,,,,,, | ||
| Vidin,observationAbout,wikidataId/Q178531,#Header,observationAbout,,,,,, | ||
| Vratsa,observationAbout,wikidataId/Q189502,#Header,observationAbout,,,,,, | ||
| Gabrovo,observationAbout,wikidataId/Q180131,#Header,observationAbout,,,,,, | ||
| Dobrich,observationAbout,wikidataId/Q168668,#Header,observationAbout,,,,,, | ||
| Kardzhali,observationAbout,wikidataId/Q192875,#Header,observationAbout,,,,,, | ||
| Kyustendil,observationAbout,wikidataId/Q189305,#Header,observationAbout,,,,,, | ||
| Lovech,observationAbout,wikidataId/Q189328,#Header,observationAbout,,,,,, | ||
| Montana,observationAbout,wikidataId/Q220121,#Header,observationAbout,,,,,, | ||
| Pazardzhik,observationAbout,wikidataId/Q186576,#Header,observationAbout,,,,,, | ||
| Pernik,observationAbout,wikidataId/Q185289,#Header,observationAbout,,,,,, | ||
| Pleven,observationAbout,wikidataId/Q165420,#Header,observationAbout,,,,,, | ||
| Plovdiv,observationAbout,wikidataId/Q459,#Header,observationAbout,,,,,, | ||
| Razgrad,observationAbout,wikidataId/Q189650,#Header,observationAbout,,,,,, | ||
| Ruse,observationAbout,wikidataId/Q160173,#Header,observationAbout,,,,,, | ||
| Silistra,observationAbout,wikidataId/Q182428,#Header,observationAbout,,,,,, | ||
| Sliven,observationAbout,wikidataId/Q178385,#Header,observationAbout,,,,,, | ||
| Smolyan,observationAbout,wikidataId/Q192888,#Header,observationAbout,,,,,, | ||
| Sofia (stolitsa),observationAbout,wikidataId/Q1585725,#Header,observationAbout,,,,,, | ||
| Sofia,observationAbout,nuts/SOF46,#Header,observationAbout,,,,,, | ||
| Stara Zagora,observationAbout,wikidataId/Q170415,#Header,observationAbout,,,,,, | ||
| Targovishte,observationAbout,wikidataId/Q185114,#Header,observationAbout,,,,,, | ||
| Haskovo,observationAbout,wikidataId/Q186254,#Header,observationAbout,,,,,, | ||
| Shumen,observationAbout,wikidataId/Q181830,#Header,observationAbout,,,,,, | ||
| Yambol,observationAbout,wikidataId/Q186569,#Header,observationAbout,,,,,, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,23 @@ | ||
|
|
||
| # Bulgaria Demographics Dataset | ||
| ## Overview | ||
| This dataset contains demographic information from Bulgaria sourced directly from the National Statistical Institute (NSI) datasets for foundational demographic and socio-economic statistics for Bulgaria. | ||
|
|
||
| ## Data Source | ||
| **Source URL:** | ||
| https://www.nsi.bg/en/statistical-data/206/649 | ||
| The data comes from Bulgaria's official statistical authority and includes comprehensive demographic variables such as population counts, age distributions, and other census-related metrics. | ||
|
|
||
| ## Caveats | ||
| This is a manual refresh, as data cannot be downloaded directly from the source API due to the NSI Firewall blocking Google Cloud IP addresses. Once the data is manually downloaded, we can run the existing pvmap to generate the output. Remember to download the population data disaggregated by districts, age, place of residence, and sex. | ||
|
|
||
| ## Processing Instructions | ||
| To process the Bulgaria Census data and generate statistical variables, use the following command from the "data" directory: | ||
|
|
||
| python3 tools/statvar_importer/stat_var_processor.py \ | ||
| --input_data='statvar_imports/Bulgaria_NSI_Demographics/test_data/BulgariaNSI_Demographics_input.csv' \ | ||
| --pv_map='statvar_imports/Bulgaria_NSI_Demographics/BulgariaNSI_Demographics_pvmap.csv' \ | ||
| --output_path='statvar_imports/Bulgaria_NSI_Demographics/test_data/BulgariaNSI_Demographics_output' \ | ||
| --config_file='statvar_imports/Bulgaria_NSI_Demographics/BulgariaNSI_Demographics_metadata.csv' \ | ||
| --existing_statvar_mcf=gs://unresolved_mcf/scripts/statvar/stat_vars.mcf | ||
|
|
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.