From ba3077d025a330d056bec34746d09edcfb9d6429 Mon Sep 17 00:00:00 2001 From: Maximilian Roos Date: Mon, 24 Dec 2018 17:12:00 -0500 Subject: [PATCH] fix --- xarray/core/dataset.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xarray/core/dataset.py b/xarray/core/dataset.py index a5f6376d399..7cc0b92ce8e 100644 --- a/xarray/core/dataset.py +++ b/xarray/core/dataset.py @@ -2912,7 +2912,7 @@ def reduce(self, func, dim=None, keep_attrs=None, numeric_only=False, else: dims = set(dim) - missing_dimensions = [dim for d in dims if d not in self.dims] + missing_dimensions = [d for d in dims if d not in self.dims] if missing_dimensions: raise ValueError('Dataset does not contain the dimensions: %s' % missing_dimensions) @@ -3711,7 +3711,7 @@ def quantile(self, q, dim=None, interpolation='linear', else: dims = set(dim) - _assert_empty([dim for d in dims if d not in self.dims], + _assert_empty([d for d in dims if d not in self.dims], 'Dataset does not contain the dimensions: %s') q = np.asarray(q, dtype=np.float64)