diff options
author | Birte Kristina Friesel <birte.friesel@uos.de> | 2023-11-27 13:22:51 +0100 |
---|---|---|
committer | Birte Kristina Friesel <birte.friesel@uos.de> | 2023-11-27 13:22:51 +0100 |
commit | 7b564fc3f766c2428ba70a449c12024607f555a7 (patch) | |
tree | cf63693295444d898d3bb5dd87995f560f699b8f /lib | |
parent | 0e8b4db2964d82a2856bca096fafbe86b76712eb (diff) |
--info: also print range of observations
Diffstat (limited to 'lib')
-rw-r--r-- | lib/cli.py | 8 | ||||
-rw-r--r-- | lib/parameters.py | 6 |
2 files changed, 14 insertions, 0 deletions
@@ -63,6 +63,14 @@ def print_info_by_name(model, by_name): ], ) ) + for attr in sorted(model.attributes(name)): + print( + " Observation {} ∈ [{:.2f}, {:.2f}]".format( + attr, + model.attr_by_name[name][attr].min(), + model.attr_by_name[name][attr].max(), + ) + ) def print_analyticinfo(prefix, info): diff --git a/lib/parameters.py b/lib/parameters.py index 99418b6..4c7cf8b 100644 --- a/lib/parameters.py +++ b/lib/parameters.py @@ -742,6 +742,12 @@ class ModelAttribute: ) return None + def min(self): + return np.min(self.data) + + def max(self): + return np.max(self.data) + def webconf_function_map(self): return self.model_function.webconf_function_map() |