Skip to content

Releases: openscm/pandas-openscm

v0.9.0

29 Aug 19:07

Choose a tag to compare

Announcements

  • We now have feature parity between the DataFrame and Series accessors (tracked in #25) ⚖️

Changelog

⚠️ Breaking Changes

  • Renamed df to pobj in [pandas_openscm.index_manipulation.update_index_levels_func] and [pandas_openscm.index_manipulation.update_index_levels_from_other_func] (#39)

🆕 Features

    • [pd.Index][pandas.Index] accessor [pandas_openscm.accessors.index.PandasIndexOpenSCMAccessor]
    • ensure multiindex related functionality: [pandas_openscm.accessors.series.PandasSeriesOpenSCMAccessor.ensure_index_is_multiindex] and [pandas_openscm.accessors.index.PandasIndexOpenSCMAccessor.ensure_is_multiindex]

    (#36)

  • More methods for [pandas_openscm.accessors.series.PandasSeriesOpenSCMAccessor], moving towards feature completeness (#25), specifically [pandas_openscm.accessors.series.PandasSeriesOpenSCMAccessor.fix_index_name_after_groupby_quantile], [pandas_openscm.accessors.series.PandasSeriesOpenSCMAccessor.groupby_except], [pandas_openscm.accessors.series.PandasSeriesOpenSCMAccessor.mi_loc] and [pandas_openscm.accessors.series.PandasSeriesOpenSCMAccessor.to_category_index] (#37)

  • More methods for [pandas_openscm.accessors.series.PandasSeriesOpenSCMAccessor] and [pandas_openscm.accessors.index.PandasIndexOpenSCMAccessor], leading to feature completeness (#25), specifically [pandas_openscm.accessors.series.PandasSeriesOpenSCMAccessor.update_index_levels], [pandas_openscm.accessors.series.PandasSeriesOpenSCMAccessor.update_index_levels_from_other], [pandas_openscm.accessors.index.PandasIndexOpenSCMAccessor.update_levels] and [pandas_openscm.accessors.index.PandasIndexOpenSCMAccessor.update_levels_from_other] (#39)

🔧 Trivial/Internal Changes

Changes

v0.8.3

09 Aug 18:12

Choose a tag to compare

Announcements

  • Nothing to announce, just checking workflows after an update to internal build machinery

Changelog

🔧 Trivial/Internal Changes

Changes

v0.8.1

08 Aug 10:48

Choose a tag to compare

Announcements

Changelog

🎉 Improvements

  • [pandas_openscm.index_manipulation.update_levels_from_other][] now supports updating levels based on multiple other levels from the index at once (see the docstring for examples).
    This update also propagates to [pandas_openscm.index_manipulation.update_index_levels_from_other_func][] and [pandas_openscm.accessors.dataframe.PandasDataFrameOpenSCMAccessor.update_index_levels_from_other][]. (#28)

Changes

v0.8.0

05 Aug 08:46

Choose a tag to compare

Announcements

  • Added some accessors for pd.Series 🎉
    • These aren't feature complete yet, see #25 for details
  • A number of breaking changes to parts of the API
    • Renamed pandas_openscm.register_pandas_accessor to pandas_openscm.register_pandas_accessors (with a trailing 's') as accessors are now also registered for [pandas Series][pandas.Series]
    • Renamed pandas_openscm.accessors.DataFramePandasOpenSCMAccessor to pandas_openscm.accessors.PandasDataFrameOpenSCMAccessor
    • Renamed df_unit_level to unit_level in pandas_openscm.accessors.PandasDataFrameOpenSCMAccessor.convert_unit_like
    • Renamed df to pobj in pandas_openscm.index_manipulation.set_index_levels_func, pandas_openscm.unit_conversion.convert_unit_from_target_series, pandas_openscm.unit_conversion.convert_unit and pandas_openscm.unit_conversion.convert_unit_like

Changelog

⚠️ Breaking Changes

    • Renamed pandas_openscm.register_pandas_accessor to [pandas_openscm.register_pandas_accessors][] (with a trailing 's') as accessors are now also registered for [pandas Series][pandas.Series]
    • Renamed pandas_openscm.accessors.DataFramePandasOpenSCMAccessor to [pandas_openscm.accessors.PandasDataFrameOpenSCMAccessor][]
    • Renamed df_unit_level to unit_level in [pandas_openscm.accessors.PandasDataFrameOpenSCMAccessor.convert_unit_like][]
    • Renamed df to pobj in [pandas_openscm.index_manipulation.set_index_levels_func][], [pandas_openscm.unit_conversion.convert_unit_from_target_series][], [pandas_openscm.unit_conversion.convert_unit][] and [pandas_openscm.unit_conversion.convert_unit_like][]

    (#24)

🆕 Features

  • Added some accessors for [pandas Series][pandas.Series] via [pandas_openscm.accessors.PandasSeriesOpenSCMAccessor][]. Note that this is not feature complete yet, tracking in #25 (#24)

🎉 Improvements

  • [pandas_openscm.index_manipulation.set_index_levels_func][], [pandas_openscm.unit_conversion.convert_unit_from_target_series][], [pandas_openscm.unit_conversion.convert_unit][] and [pandas_openscm.unit_conversion.convert_unit_like][] now explicitly support [pd.Series][pandas.Series] (#24)

🔧 Trivial/Internal Changes

Changes

v0.7.0

24 Jul 18:39

Choose a tag to compare

Announcements

Changelog

🆕 Features

    • Added unit conversion APIs: [pandas_openscm.unit_conversion.convert_unit] and [pandas_openscm.unit_conversion.convert_unit_like] and the corresponding accessors [pandas_openscm.accessors.DataFramePandasOpenSCMAccessor.convert_unit] and [pandas_openscm.accessors.DataFramePandasOpenSCMAccessor.convert_unit_like]
    • Added the helper: [pandas_openscm.index_manipulation.ensure_is_multiindex] and the corresponding accessors [pandas_openscm.accessors.DataFramePandasOpenSCMAccessor.ensure_index_is_multiindex] and [pandas_openscm.accessors.DataFramePandasOpenSCMAccessor.eiim]

    (#23)

Changes

v0.6.0

16 Jul 11:56

Choose a tag to compare

Announcements

  • Updated minimum numpy version to 1.26.0, the earliest that is not in end-of-life. Fixed the numpy pin for Python 3.13 to >=2.1.0, the first numpy version which supported Python 3.13

Changelog

⚠️ Breaking Changes

  • Updated minimum numpy version to 1.26.0, the earliest that is not in end-of-life. Fixed the numpy pin for Python 3.13 to >=2.1.0, the first numpy version which supported Python 3.13. (#21)

🔧 Trivial/Internal Changes

Changes

v0.5.1

23 May 09:07

Choose a tag to compare

Announcements

  • Added functionality to set levels. See the examples section in the docs

Changelog

🆕 Features

  • Added [pandas_openscm.index_manipulation.set_levels][] and the corresponding accessor [pandas_openscm.accessors.DataFramePandasOpenSCMAccessor.set_index_levels][] (#18)

Changes

v0.5.0

10 May 11:38

Choose a tag to compare

Announcements

Changelog

⚠️ Breaking Changes

    • Required db_dir to be passed when initialising [pandas_openscm.db.reader.OpenSCMDBReader][]. This is required to support portable databases
    • Renamed out_column_type to out_columns_type in [pandas_openscm.io.load_timeseries_csv][] for consistency with the rest of the API
    • Bumped the minimum supported version of filelock to 3.12.3, as only this version handles automatic creation of directories for the lock

    (#19)

🆕 Features

    • Made the database portable by only storing relative paths in the file map. This allows the database to be converted to an archive with [pandas_openscm.db.OpenSCMDB.to_gzipped_tar_archive][] and then unpacked elsewhere with [pandas_openscm.db.OpenSCMDB.from_gzipped_tar_archive][]
    • Added [pandas_openscm.db.path_handling][] to clarify how we handle paths internally to support portability
    • Added support for specifying the name of the output columns via [pandas_openscm.db.OpenSCMDB.load][], [pandas_openscm.db.reader.OpenSCMDBReader.load][] and [pandas_openscm.io.load_timeseries_csv][]

    (#19)

🎉 Improvements

    • Added the explicit [pandas_openscm.db.backends][] module to handle the backends we support more clearly
    • Added [pandas_openscm.db.backends.DataBackendOptions.guess_backend][] and [pandas_openscm.db.backends.IndexBackendOptions.guess_backend][] to allow for move convenient inference of the backend to use with different files

    (#19)

🔧 Trivial/Internal Changes

Changes

v0.4.1

12 Apr 15:29

Choose a tag to compare

Announcements

  • Fixed a bug in the index level updating, see below. Set remove_unused_levels=False to turn off this behaviour.

Changelog

🐛 Bug Fixes

  • Fixed up [pandas_openscm.index_manipulation.update_levels][].
    It now drops unused levels by default first, to avoid applying the updates to values that aren't being used.
    The same fixes are propagated to [pandas_openscm.accessors.DataFramePandasOpenSCMAccessor.update_index_levels][] and [pandas_openscm.index_manipulation.update_index_levels_func][]. (#14)

Changes

v0.4.0

11 Apr 18:06

Choose a tag to compare

Announcements

  • Added pandas_openscm.index_manipulation.update_levels and pandas_openscm.accessors.DataFramePandasOpenSCMAccessor.update_index_levels

Changelog

🆕 Features

  • Added [pandas_openscm.index_manipulation.update_levels][] and the corresponding accessor [pandas_openscm.accessors.DataFramePandasOpenSCMAccessor.update_index_levels][] (#13)

Changes