From 87bf4b8ff005f009e2542234ba93380d4c7df787 Mon Sep 17 00:00:00 2001 From: MarionetteSHF Date: Mon, 17 Jan 2022 09:47:20 -0500 Subject: [PATCH 1/5] add hello world --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 513b7a0..bbff6c9 100644 --- a/README.md +++ b/README.md @@ -116,3 +116,4 @@ class CustomDataset: ### ACS - OpenFisca-US-compatible - Contains OpenFisca-US-compatible input arrays. +###hello world \ No newline at end of file From dac5e16c390194edc1707f7f27dcfd392cb28104 Mon Sep 17 00:00:00 2001 From: MarionetteSHF Date: Mon, 17 Jan 2022 09:49:37 -0500 Subject: [PATCH 2/5] add hello world --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index bbff6c9..ffbca91 100644 --- a/README.md +++ b/README.md @@ -116,4 +116,4 @@ class CustomDataset: ### ACS - OpenFisca-US-compatible - Contains OpenFisca-US-compatible input arrays. -###hello world \ No newline at end of file +### hello world \ No newline at end of file From 279368f72b72a6dc354089ea2c6db88599e5036c Mon Sep 17 00:00:00 2001 From: MarionetteSHF Date: Mon, 17 Jan 2022 09:52:42 -0500 Subject: [PATCH 3/5] Two hellow --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index ffbca91..28e407b 100644 --- a/README.md +++ b/README.md @@ -116,4 +116,4 @@ class CustomDataset: ### ACS - OpenFisca-US-compatible - Contains OpenFisca-US-compatible input arrays. -### hello world \ No newline at end of file +### hello world hello \ No newline at end of file From c72f37642a5e2f9b0f4c953140d13ddef7888720 Mon Sep 17 00:00:00 2001 From: MarionetteSHF Date: Sat, 22 Jan 2022 20:51:53 -0500 Subject: [PATCH 4/5] define tax_unit_function --- openfisca_us_data/datasets/cps/cps.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/openfisca_us_data/datasets/cps/cps.py b/openfisca_us_data/datasets/cps/cps.py index a5e9982..c3c9c5a 100644 --- a/openfisca_us_data/datasets/cps/cps.py +++ b/openfisca_us_data/datasets/cps/cps.py @@ -40,7 +40,7 @@ def generate(year: int) -> None: add_personal_variables(cps, person) add_personal_income_variables(cps, person) add_SPM_variables(cps, spm_unit) - + add_tax_unit_variables(cps, tax_unit) raw_data.close() cps.close() @@ -147,3 +147,11 @@ def add_SPM_variables(cps: h5py.File, spm_unit: DataFrame): for openfisca_variable, asec_variable in SPM_RENAMES.items(): cps[openfisca_variable] = spm_unit[asec_variable] + + +def add_tax_unit_variables(cps: h5py.File, tax_unit: DataFrame): + cps["e00200p"] = tax_unit.ACTC_CRD + cps["e00200s"] = tax_unit.AGI + cps["e00900s"] = tax_unit.CTC_CRD + cps["pencon_p"] = tax_unit.FED_RET + cps["pencon_s"] = tax_unit.MARG_TAX From bef1c768e8aafc1d64968730ae99c5041e38261f Mon Sep 17 00:00:00 2001 From: MarionetteSHF Date: Sun, 6 Feb 2022 11:53:59 -0500 Subject: [PATCH 5/5] 69checked and solved --- .idea/.gitignore | 8 ++++++++ .idea/aws.xml | 17 +++++++++++++++++ .idea/inspectionProfiles/profiles_settings.xml | 6 ++++++ .idea/misc.xml | 4 ++++ .idea/modules.xml | 8 ++++++++ .idea/openfisca-us-data.iml | 15 +++++++++++++++ .idea/vcs.xml | 6 ++++++ openfisca_us_data/datasets/cps/cps.py | 9 ++------- 8 files changed, 66 insertions(+), 7 deletions(-) create mode 100644 .idea/.gitignore create mode 100644 .idea/aws.xml create mode 100644 .idea/inspectionProfiles/profiles_settings.xml create mode 100644 .idea/misc.xml create mode 100644 .idea/modules.xml create mode 100644 .idea/openfisca-us-data.iml create mode 100644 .idea/vcs.xml diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..13566b8 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,8 @@ +# Default ignored files +/shelf/ +/workspace.xml +# Editor-based HTTP Client requests +/httpRequests/ +# Datasource local storage ignored files +/dataSources/ +/dataSources.local.xml diff --git a/.idea/aws.xml b/.idea/aws.xml new file mode 100644 index 0000000..03f1bb6 --- /dev/null +++ b/.idea/aws.xml @@ -0,0 +1,17 @@ + + + + + + + \ No newline at end of file diff --git a/.idea/inspectionProfiles/profiles_settings.xml b/.idea/inspectionProfiles/profiles_settings.xml new file mode 100644 index 0000000..105ce2d --- /dev/null +++ b/.idea/inspectionProfiles/profiles_settings.xml @@ -0,0 +1,6 @@ + + + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000..ab98567 --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..072e1dc --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/openfisca-us-data.iml b/.idea/openfisca-us-data.iml new file mode 100644 index 0000000..5fd47d3 --- /dev/null +++ b/.idea/openfisca-us-data.iml @@ -0,0 +1,15 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..94a25f7 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/openfisca_us_data/datasets/cps/cps.py b/openfisca_us_data/datasets/cps/cps.py index c3c9c5a..0fd4215 100644 --- a/openfisca_us_data/datasets/cps/cps.py +++ b/openfisca_us_data/datasets/cps/cps.py @@ -121,7 +121,7 @@ def add_personal_income_variables(cps: h5py.File, person: DataFrame): cps["e02100"] = person.FRSE_VAL cps["e02400"] = person.SS_VAL cps["e02300"] = person.UC_VAL - + cps["pencon"] = np.zeros(len(person.index), dtype=np.int32) # Pensions/annuities other_inc_type = person.OI_OFF cps["e01500"] = other_inc_type.isin((2, 13)) * person.OI_VAL @@ -149,9 +149,4 @@ def add_SPM_variables(cps: h5py.File, spm_unit: DataFrame): cps[openfisca_variable] = spm_unit[asec_variable] -def add_tax_unit_variables(cps: h5py.File, tax_unit: DataFrame): - cps["e00200p"] = tax_unit.ACTC_CRD - cps["e00200s"] = tax_unit.AGI - cps["e00900s"] = tax_unit.CTC_CRD - cps["pencon_p"] = tax_unit.FED_RET - cps["pencon_s"] = tax_unit.MARG_TAX +