Skip to content

Commit

Permalink
Use a 11 day window when computing climatology in -m variance
Browse files Browse the repository at this point in the history
This closes #16
  • Loading branch information
tnipen committed Apr 24, 2017
1 parent 10a5868 commit b3ac7b9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions wxgen/plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,7 @@ def __init__(self):
Plot. __init__(self)
self._sets_xticks = True
self._normalize = False
self._normalization_window = 11

def plot(self, sims, truth):
if self.thresholds is None:
Expand Down Expand Up @@ -395,7 +396,7 @@ def compute_truth_variance(self, array, scales):
otherwise the fcst variance is higher because obs gets the advantage of using its own
climatology.
"""
clim = wxgen.util.climatology(truth)
clim = wxgen.util.climatology(truth, self._normalization_window)
std = 1
if self._normalize:
std = np.nanstd(truth, axis=1)
Expand Down Expand Up @@ -429,7 +430,7 @@ def compute_sim_variance(self, array, scales):
import astropy.convolution
N = array.shape[1]

clim = wxgen.util.climatology(array, 11)
clim = wxgen.util.climatology(array, self._normalization_window)
std = 1
if self._normalize:
std = np.nanstd(array, axis=1)
Expand Down

0 comments on commit b3ac7b9

Please sign in to comment.