From 166d5113ee1914c8dd9293a3829148cf1dfe85e6 Mon Sep 17 00:00:00 2001 From: Matt Rigby Date: Fri, 19 Apr 2024 06:45:27 +0100 Subject: [PATCH] Changed behaviour so that Series/DataArray that is all NaN is returned, instead of raising an error --- openghg_calscales/functions.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openghg_calscales/functions.py b/openghg_calscales/functions.py index 200d255..970b786 100644 --- a/openghg_calscales/functions.py +++ b/openghg_calscales/functions.py @@ -175,7 +175,7 @@ def convert(c, species, scale_original, scale_new): # Check that c is not all NaNs if np.isnan(c).all(): - raise ValueError("c is all NaNs.") + return c # Construct graph G = _scale_graph(species.lower())