Releases: IAMconsortium/pyam
Release v0.13.0
Release v0.13.0
Highlights
- Add a
unit_mapping
attribute to show a variable-unit dictionary. - Support plotting of continuous-time data by automatically using the time domain as x-axis in many plots.
- Improve the performance of the
rename()
method.
API changes
PR #550 harmonized the behavior of the rename()
function when the renaming creates overlapping timeseries data. Before, this raised an error in case there was a conflict with existing data, but automatically performed a groupby-sum when mapping to the same coordinates. This was marked as deprecated; in the future, an error will be raised for any overlapping coordinates after the rename operation.
PR #548 added a unit_mapping
attribute. This will replace the variables(include_units=True)
method.
Individual updates
Release v0.12.0
Release v0.12.0
Highlights
- Add algebraic operations working directly on the timeseries data including automatic handling of units.
- Drop negative weights when performing weighted regional aggregation by default.
- Allow recursive aggregation when (some) intermediate variables exist and perform validation of the existing intermediate variables.
API changes
PR #534 changed the behavior of the aggregate_region()
method when performing weighted region aggregation. By default, if any weights are negative, the corresponding aggregated values are dropped from the resulting IamDataFrame. The previous behavior can be achieved by setting drop_negative_weights=False
.
Individual updates
- #543 Add a tutorial for working with algebraic operations
- #541 Support units in binary operations
- #538 Add option to set defaults in binary operations
- #537 Enhance binary ops to support numerical arguments
- #534 Add feature to drop negative weights
- #532 Add an option to skip existing intermediate variables when aggregating recursively
- #533 Add an
apply()
function for custom mathematical operations - #527 Add an in-dataframe basic mathematical operations
subtract
,add
,multiply
,divide
- #523 Add feature to compute weights for de-biasing using count
- #519 Enable explicit
label
and fix for non-string items in plot legend
Release v0.11.0
Release v0.11.0
Highlights
- Easily order data in the line plot feature.
- Add a module for reading data from the UNFCCC Data Inventory via the PIK-PRIMAP unfccc-di-api package.
- Improved integration with any IIASA Scenario Explorer instance:
read non-default versions from the connected database and obtain the "audit" info (scenario upload/edit timestamp and user). - Performance improvements when aggregating or concatenating data.
- Refactor the entire code base to the Black code style.
API changes
PR #507 harmonizes the behavior of the aggregate()
and aggregate_region()
methods when performing "empty" aggregation, i.e., no components exist to perform the requested aggregation. In the new implementation, an empty IamDataFrame is returned if append=False
(instead of None).
PR #488 changes the default behavior when initializing an IamDataFrame from xlsx: now, all sheets names starting with data
will be parsed for timeseries data.
Individual updates
- #510 Improve performance of
pyam.concat()
- #508 Bugfix for non-empty but invisible header and no rows in 'meta' sheet
- #507 Refactor aggregation-functions to increase performance
- #502 Switch to Black code style
- #499 Implement
order
feature in line plot - #497 Add a module for reading data from the UNFCCC Data Inventory
- #496 Enable loading meta from csv file
- #494 Small performance improvements
- #491 Allow loading meta from file without exclude columns or with empty rows
- #488 Read all sheets starting with
data
when reading from xlsx - #486 Enable reading non-default scenario versions from IIASA API
- #483 Add a tutorial for integration with R
- #481 Enable custom index columns
- #477 Add a nightly test suite
- #476 Add docstrings to plotting functions
df.plot.<kind>()
- #471 Add a
iiasa.Connection.properties()
function to retrieve scenario audit data
Release v0.10.0
Release v0.10.0
Highlights
- Refactor the plotting library for better UX and consistency with pandas,
matplotlib and seaborn. - Add a
sankey()
feature to the plotting library. - Rework the documentation and tutorials.
API changes
Several PRs in this release changed the implementation of the plotting library
for better UX and consistency with pandas, matplotlib and seaborn.
Replace the calls to plotting features by the following:
plot(...)
(orplot(kind='line', ...)
) forline_plot()
plot.stack(...)
forstack_plot()
plot.bar()
forbar_plot()
- ...
These PRs also add an order
arg to the plotting functions, and the levels
are ordered based on the run_control()['order']
dictionary by default.
Individual updates
- #475 Add a scatter plot example to the gallery
- #473 Refactor to plotting API following pandas/matplotlib implementation
- #472 Add a
sankey()
example to the plotting gallery - #470 Add two types of
order
arg tobarplot()
- #467 Refactor the GAMS-pyam tutorial to use the gamstransfer module
- #466 Add a
sankey()
function to create sankey diagrams - #464 Add
order
arg tostackplot()
- #463 Clarification of initialization-error message if file does not exist
Release v0.9.0
Release v0.9.0
Highlights
- Extend the data format to work with dimensionless variables (i.e., accept "empty" units).
- Refactor the
interpolate()
feature to accept a list of years ordatetime
instances. - Add the list of authors/contributors to the docs.
API changes
PR #456 changed the interface of the interpolate()
feature to do the operation inplace (previous behaviour) or return a new instance (future default). A deprecation warning is written if a user does not provide the arg inplace
to warn of the future change.
Individual updates
- #461 Add list of authors to repo and docs pages
- #459 Add a
get_variable_components()
function to retrieve or join variable components - #458 Enable
Path
for IamDataFrame initialization - #456 Speed up interpolation and support interpolation for multiple time-points
- #454 Enable dimensionless units and fix
info()
if IamDataFrame is empty - #451 Fix unit conversions from C to CO2eq
- #450 Defer logging set-up to when the first logging message is generated
- #445 Prevent conflicts between attributes and data/meta columns
- #444 Use warnings module for deprecation warnings
Release v0.8.0
Release v0.8.0
Highlights
- Add a boxplot visualization feature to the plotting toolbox.
- Implement an API to read data from World Bank Open Data Catalogue.
- Write a tutorial illustrating how to read model results from a GAMS gdx file.
- Define
index
,model
,scenario
, ... attributes and show a summary of the index dimensions onprint()
. - Refactor the timeseries data backend for improved performance.
API changes
PR #432 added attributes to access the list of (unique) items of each index dimension (model
, scenario
, ...). The PR also marked as deprecated the equivalent functions (models()
, scenarios()
, ...). The new behaviour is closer (though still different) to what a pandas user would expect.
Notes
PR #420 added an object IamDataFrame._data
to handle timeseries data internally. This is implemented as a pandas.Series
(instead of the previous long-format pandas.DataFrame
) to improve performance. The previous behaviour with IamDataFrame.data
is maintained via getter and setter functions.
Individual updates
- #440 Add
boxplot()
visualization feature - #438 Add an
index
attribute of model-scenario combinations - #437 Improved test for appending mismatched timeseries
- #436 Raise an error with appending mismatching timeseries index dimensions
- #432 Add attributes to access index dimensions
- #429 Fix return type of
validate()
after data refactoring - #427 Add an
info()
function and use inprint(IamDataFrame)
- #424 Add a tutorial reading results from a GAMS model (via a gdx file).
- #420 Add a
_data
object (implemented as a pandas.Series) to handle timeseries data internally. - #418 Read data from World Bank Open Data Catalogue as IamDataFrame.
- #416 Include
meta
in new IamDataFrames returned by aggregation functions.
Release v0.7.0
Release v0.7.0
Highlights
- Add new features for aggregating and downscaling timeseries data.
- Update the plotting library for compatibility with the latest matplotlib release.
- Refactor the feature to read data directly from an IIASA scenario database API.
- Migrate the continuous-integration (CI) infrastructure from Travis & Appveyor to GitHub Actions and use CodeCov.io instead of coveralls.io for test coverage metrics.
API changes
PR #413 changed the return type of pyam.read_iiasa()
and pyam.iiasa.Connection.query()
to an IamDataFrame
(instead of a pandas.DataFrame
) and loads meta-indicators by default.
Also, the following functions were deprecated for package consistency:
index()
replacesscenario_list()
for an overview of all scenariosmeta_columns
(attribute) replacesavailable_metadata()
meta()
replacesmetadata()
PR #402 changed the default behaviour of as_pandas()
to include all columns of meta
in the returned dataframe, or only merge columns given by the renamed argument meta_cols
. The feature to discover meta-columns from a dictionary was split out into a utility function pyam.plotting.mpl_args_to_meta_cols()
.
Individual Updates
- #413 Refactor IIASA-connection-API and rework all related tests.
- #412 Add building the docs to GitHub Actions CI.
- #411 Add feature to pass an explicit weight dataframe to
downscale_region()
. - #410 Activate tutorial tests on GitHub Actions CI (py3.8).
- #409 Remove travis and appveyor CI config.
- #408 Update badges on the docs page and readme.
- #407 Add Codecov to Github Actions CI.
- #405 Add ability for recursivley aggregating variables.
- #402 Refactor
as_pandas()
and docs for more consistent description ofmeta
. - #401 Read credentials for IIASA-API-Connection by default from known location.
- #396 Enable casting to
IamDataFrame
multiple times. - #394 Switch CI to Github Actions.
- #393 Import ABC from collections.abc for Python 3.10 compatibility.
- #380 Add compatibility with latest matplotlib and py3.8
Release v0.6.0
Release v0.6.0
Highlights
- Add feature to aggregate timeseries at sub-annual time resolution
- Refactored the iam-units utility from a submodule to a dependency
- Clean up documentation and dependencies
Individual Updates
- #386 Enables unit conversion to apply to strings with "-equiv" in them.
- #384 Add documentation for the pyam.iiasa.Connection class.
- #382 Streamline dependencies and implementation of xlsx-io
- #373 Extends the error message when initializing with duplicate rows.
- #370 Allowed filter to work with np.int64 years and np.datetime64 dates.
- #369
convert_unit()
supports GWP conversion of same GHG species without context, lower-case aliases for species symbols. - #361 iam-units refactored from a Git submodule to a Python dependency of pyam.
- #322 Add feature to aggregate timeseries at sub-annual time resolution
Release v0.5.0
Release v0.5.0
Highlights
- Improved feature for unit conversion using the pint package and the IAMconsortium/units repository, providing out-of-the-box conversion of unit definitions commonly used in integrated assessment research and energy systems modelling; see this tutorial for more information
- Increased support for operations on timeseries data with continuous-time resolution
- New tutorial for working with various input data formats; take a look here
- Rewrite and extension of the documentation pages for the API; read the new docs!
API changes
PR #341 changed the API of IamDataFrame.convert_unit()
from a dictionary to explicit kwargs current
, to
and factor
(now optional, using pint
if not specified).
PR #334 changed the arguments of IamDataFrame.interpolate()
and pyam.fill_series()
to time
. It can still be an integer (i.e., a year).
With PR #337, initializing an IamDataFrame with n/a
entries in columns other than value
raises an error.
Individual Updates
- #354 Fixes formatting of API parameter docstrings
- #352 Bugfix when using
interpolate()
on data with extra columns - #349 Fixes an issue with checking that time columns are equal when appending IamDataFrames
- #348 Extend pages for API docs, clean up docstrings, and harmonize formatting
- #347 Enable contexts and custom UnitRegistry with unit conversion
- #341 Use
pint
and IIASA-ene-units repo for unit conversion - #339 Add tutorial for dataframe format io
- #337 IamDataFrame to throw an error when initialized with n/a entries in columns other than
value
- #334 Enable interpolate to work on datetimes
⚠️ Warning ⚠️
This release includes the repository IAMconsortium/units as a submodule, but GitHub currently does not support including submodules in the archives distributed with a release. Please download the content of the units folder directly from the repository..
Release v0.4.1
Release v0.4.1
Summary
This is a patch release to enable compatibility with pandas v1.0.
It also adds experimental support of frictionless datapackage
format (read more on GitHub).