Redistribute 2010-2019 census data onto 2020 census boundaries
Project description
sdc-census10to20
Redistribute 2010-2019 census data onto 2020 census boundaries.
This is the Python port of the R package
sdc.census10to20, used by
the Social Data Commons pipelines to standardize tract- and block-group-level
data across the 2020 decennial census boundary changes.
Install
pip install sdc-census10to20
Quick start
import pandas as pd
from sdc_census10to20 import standardize_all
df = pd.DataFrame({
"geoid": ["51059450100", "51059450200"],
"year": [2018, 2018],
"measure": ["population", "population"],
"value": [3000, 4500],
"moe": [pd.NA, pd.NA],
})
standardized = standardize_all(df)
See the documentation for the full API reference and a worked example with Virginia tract-level data.
Releasing
This package uses PyPI Trusted Publishing, so no API tokens are stored in GitHub.
One-time setup (done by a maintainer):
- Register the project name on TestPyPI and
PyPI with a "pending publisher" pointing at this repo
and workflow file (
.github/workflows/publish.yml). - Configure two GitHub environments on the repo:
testpypiandpypi.
To cut a release:
- Bump
versioninpyproject.toml, updateCHANGELOG.md. - Commit and tag:
git tag census10to20-v0.1.0 && git push --tags. - The
publish.ymlworkflow builds the wheel, uploads to TestPyPI first, then PyPI on success.
To publish docs:
The docs.yml workflow runs on every push to main that touches
packages/sdc-census10to20/. No tag required.
License
MIT
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sdc_census10to20-0.1.0.tar.gz.
File metadata
- Download URL: sdc_census10to20-0.1.0.tar.gz
- Upload date:
- Size: 8.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f8feb2cc09515a1710479fd861414b1af274e756e0f615cda2738ec53423f08c
|
|
| MD5 |
04bd12a09634396d9c476b8f500bf80b
|
|
| BLAKE2b-256 |
8cf11b2f66ad8889f02cb54f4ffe9fc09e2861eff23f14d5b323f356fcabd3c2
|
Provenance
The following attestation bundles were made for sdc_census10to20-0.1.0.tar.gz:
Publisher:
publish-census10to20.yml on dads2busy/Social-Data-Commons
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
sdc_census10to20-0.1.0.tar.gz -
Subject digest:
f8feb2cc09515a1710479fd861414b1af274e756e0f615cda2738ec53423f08c - Sigstore transparency entry: 1710793142
- Sigstore integration time:
-
Permalink:
dads2busy/Social-Data-Commons@58690ecad94b218d10074e489d0194b1269c0cab -
Branch / Tag:
refs/tags/census10to20-v0.1.0 - Owner: https://github.com/dads2busy
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-census10to20.yml@58690ecad94b218d10074e489d0194b1269c0cab -
Trigger Event:
push
-
Statement type:
File details
Details for the file sdc_census10to20-0.1.0-py3-none-any.whl.
File metadata
- Download URL: sdc_census10to20-0.1.0-py3-none-any.whl
- Upload date:
- Size: 7.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e61587d3276dde8deb9a67e7b7a4745a3800708bafe4bd9a74cb90ec061825c4
|
|
| MD5 |
e2abaa02d5a1fe99eada7704c87ccbe6
|
|
| BLAKE2b-256 |
b9f5e86dc820c11cce1c84729aae5ac81f08965e6c5a948692563bfd2f5c0b45
|
Provenance
The following attestation bundles were made for sdc_census10to20-0.1.0-py3-none-any.whl:
Publisher:
publish-census10to20.yml on dads2busy/Social-Data-Commons
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
sdc_census10to20-0.1.0-py3-none-any.whl -
Subject digest:
e61587d3276dde8deb9a67e7b7a4745a3800708bafe4bd9a74cb90ec061825c4 - Sigstore transparency entry: 1710793172
- Sigstore integration time:
-
Permalink:
dads2busy/Social-Data-Commons@58690ecad94b218d10074e489d0194b1269c0cab -
Branch / Tag:
refs/tags/census10to20-v0.1.0 - Owner: https://github.com/dads2busy
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-census10to20.yml@58690ecad94b218d10074e489d0194b1269c0cab -
Trigger Event:
push
-
Statement type: