Skip to content

Commit 2c44efe

Browse files
committed
Merge branch 'main' into develop
2 parents 9a0592e + 9f22a6d commit 2c44efe

4 files changed

Lines changed: 27 additions & 4 deletions

File tree

CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,19 @@
22

33
## 0.2 series
44

5+
### 0.2.4
6+
7+
* Made figure sizes for visualization functions customizable via `petab.visualize.plotting.DEFAULT_FIGSIZE`
8+
by @dweindl in https://github.com/PEtab-dev/libpetab-python/pull/222
9+
* Fixed Handling missing `nominalValue` in `Problem.get_x_nominal`
10+
by @dweindl in https://github.com/PEtab-dev/libpetab-python/pull/223
11+
* Fixed pandas 2.1.0 `FutureWarnings`
12+
by @dweindl in https://github.com/PEtab-dev/libpetab-python/pull/226
13+
* Added pre-commit-config, ran black, isort, ...
14+
by @dweindl in https://github.com/PEtab-dev/libpetab-python/pull/225
15+
16+
**Full Changelog**: https://github.com/PEtab-dev/libpetab-python/compare/v0.2.3...v0.2.4
17+
518
### 0.2.3
619

720
* Fixed validation failures in case of missing optional fields in visualization tables

doc/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
# -- Project information -----------------------------------------------------
2121

2222
project = "libpetab-python"
23-
copyright = "2018, the PEtab developers"
23+
copyright = "2018-2023, the PEtab developers"
2424
author = "PEtab developers"
2525

2626
# The full version, including alpha/beta/rc tags

petab/core.py

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,15 +70,25 @@ def write_simulation_df(df: pd.DataFrame, filename: Union[str, Path]) -> None:
7070
df.to_csv(filename, sep="\t", index=False)
7171

7272

73-
def get_visualization_df(visualization_file: Union[str, Path]) -> pd.DataFrame:
73+
def get_visualization_df(
74+
visualization_file: Union[str, Path, pd.DataFrame, None]
75+
) -> Union[pd.DataFrame, None]:
7476
"""Read PEtab visualization table
7577
7678
Arguments:
77-
visualization_file: URL or filename of PEtab visualization table
79+
visualization_file:
80+
URL or filename of PEtab visualization table to read from,
81+
or a DataFrame or None that will be returned as is.
7882
7983
Returns:
8084
Visualization DataFrame
8185
"""
86+
if visualization_file is None:
87+
return None
88+
89+
if isinstance(visualization_file, pd.DataFrame):
90+
return visualization_file
91+
8292
try:
8393
types = {PLOT_NAME: str}
8494
vis_spec = pd.read_csv(

petab/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
"""PEtab library version"""
2-
__version__ = "0.2.3"
2+
__version__ = "0.2.4"

0 commit comments

Comments
 (0)