From fc47574ef5293df76d19711eb247f6eb1e9651d4 Mon Sep 17 00:00:00 2001 From: Daniel Chudnov Date: Mon, 13 Mar 2023 18:51:13 -0400 Subject: [PATCH] Removed walrus operator (only 3.8+), added scipy to requirements, closes #61, #66 --- growthviz/charts.py | 3 ++- requirements.txt | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/growthviz/charts.py b/growthviz/charts.py index 78bc8be..4de772b 100644 --- a/growthviz/charts.py +++ b/growthviz/charts.py @@ -460,7 +460,8 @@ def overlap_view_double_pediatrics( color_secondary = "tab:blue" # Allow zooming in a bit if this is a young subject - if (maxage := individual["ageyears"].max()) < 10: + maxage = individual["ageyears"].max() + if maxage < 10: ax1_xlim = [0, maxage * 1.1] # Find stature at P95 for maxage pct_max = round( diff --git a/requirements.txt b/requirements.txt index b2f44c9..be7b14e 100644 --- a/requirements.txt +++ b/requirements.txt @@ -3,4 +3,5 @@ jupyter-server<2.0.0 matplotlib>=3.3.4 pandas>=1.2.2 qgrid>=1.3.1 +scipy seaborn>=0.11.1