Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use native iris functions in multi-model statistics #1150

Merged
merged 11 commits into from
Jun 7, 2021
5 changes: 3 additions & 2 deletions esmvalcore/_recipe_checks.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
import yamale

from ._data_finder import get_start_end_year
from .preprocessor import PreprocessingTask, TIME_PREPROCESSORS
from .preprocessor import TIME_PREPROCESSORS, PreprocessingTask
from .preprocessor._multimodel import STATISTIC_MAPPING

logger = logging.getLogger(__name__)

Expand Down Expand Up @@ -191,7 +192,7 @@ def extract_shape(settings):

def valid_multimodel_statistic(statistic):
"""Check that `statistic` is a valid argument for multimodel stats."""
valid_names = ["mean", "median", "std", "min", "max"]
valid_names = ['std'] + list(STATISTIC_MAPPING.keys())
valid_patterns = [r"^(p\d{1,2})(\.\d*)?$"]
if not (statistic in valid_names
or re.match(r'|'.join(valid_patterns), statistic)):
Expand Down
Loading