diff --git a/CHANGELOG.md b/CHANGELOG.md index c0f6f79..6828fcf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,8 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.2.2] - 2024-09-18 11:38:21 + ## [1.2.1] - 2024-09-18 10:05:45 ### Fixed @@ -31,6 +33,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.2.2]: https://github.com/PolicyEngine/policyengine-us-data/compare/1.2.1...1.2.2 [1.2.1]: https://github.com/PolicyEngine/policyengine-us-data/compare/1.2.0...1.2.1 [1.2.0]: https://github.com/PolicyEngine/policyengine-us-data/compare/1.1.0...1.2.0 [1.1.0]: https://github.com/PolicyEngine/policyengine-us-data/compare/1.0.0...1.1.0 diff --git a/changelog.yaml b/changelog.yaml index d1f4830..6dab6a1 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -18,3 +18,8 @@ fixed: - Data download URLs. date: 2024-09-18 10:05:45 +- bump: patch + changes: + removed: + - Survey Enhance is no longer used as a top-level import. + date: 2024-09-18 11:38:21 diff --git a/policyengine_uk_data/utils/imputations/consumption.py b/policyengine_uk_data/utils/imputations/consumption.py index 2270f72..b0d4c75 100644 --- a/policyengine_uk_data/utils/imputations/consumption.py +++ b/policyengine_uk_data/utils/imputations/consumption.py @@ -1,4 +1,3 @@ -from survey_enhance.impute import Imputation import pandas as pd from pathlib import Path import numpy as np @@ -133,6 +132,8 @@ def uprate_lcfs_table( def save_imputation_models(): + from survey_enhance.impute import Imputation + consumption = Imputation() lcfs_household = pd.read_csv( LCFS_TAB_FOLDER / "lcfs_2021_dvhh_ukanon.tab", diff --git a/policyengine_uk_data/utils/imputations/income.py b/policyengine_uk_data/utils/imputations/income.py index 95d3947..6460e32 100644 --- a/policyengine_uk_data/utils/imputations/income.py +++ b/policyengine_uk_data/utils/imputations/income.py @@ -1,4 +1,3 @@ -from survey_enhance.impute import Imputation import pandas as pd from pathlib import Path import numpy as np @@ -85,6 +84,8 @@ def generate_spi_table(spi: pd.DataFrame): def save_imputation_models(): + from survey_enhance.impute import Imputation + income = Imputation() spi = pd.read_csv(SPI_TAB_FOLDER / "put2021uk.tab", delimiter="\t") spi = generate_spi_table(spi) diff --git a/policyengine_uk_data/utils/imputations/vat.py b/policyengine_uk_data/utils/imputations/vat.py index 9519212..d254ee3 100644 --- a/policyengine_uk_data/utils/imputations/vat.py +++ b/policyengine_uk_data/utils/imputations/vat.py @@ -1,4 +1,3 @@ -from survey_enhance.impute import Imputation import pandas as pd from pathlib import Path import numpy as np @@ -30,6 +29,8 @@ def generate_etb_table(etb: pd.DataFrame): def save_imputation_models(): + from survey_enhance.impute import Imputation + vat = Imputation() etb = pd.read_csv( ETB_TAB_FOLDER / "householdv2_1977-2021.tab", diff --git a/policyengine_uk_data/utils/imputations/wealth.py b/policyengine_uk_data/utils/imputations/wealth.py index 2513f5d..a9188b3 100644 --- a/policyengine_uk_data/utils/imputations/wealth.py +++ b/policyengine_uk_data/utils/imputations/wealth.py @@ -1,4 +1,3 @@ -from survey_enhance.impute import Imputation import pandas as pd from pathlib import Path import numpy as np @@ -133,6 +132,8 @@ def generate_was_table(was: pd.DataFrame): def save_imputation_models(): + from survey_enhance.impute import Imputation + was = pd.read_csv( WAS_TAB_FOLDER / "was_round_7_hhold_eul_march_2022.tab", sep="\t", diff --git a/pyproject.toml b/pyproject.toml index 1c07374..85fe847 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "policyengine_uk_data" -version = "1.2.1" +version = "1.2.2" description = "A package to create representative microdata for the UK." readme = "README.md" authors = [