From 8546e6343048dcebcfa7f7c2e54dc5fb408a3bdc Mon Sep 17 00:00:00 2001 From: ShixuanZhang Date: Wed, 30 Oct 2024 00:09:26 -0500 Subject: [PATCH] Bug fix for mean climate metrics plot function --- zppy/templates/pcmdi_diags/derived_variable.json | 0 zppy/templates/pcmdi_diags/mean_climate_plot_driver.py | 4 +++- 2 files changed, 3 insertions(+), 1 deletion(-) mode change 100644 => 100755 zppy/templates/pcmdi_diags/derived_variable.json diff --git a/zppy/templates/pcmdi_diags/derived_variable.json b/zppy/templates/pcmdi_diags/derived_variable.json old mode 100644 new mode 100755 diff --git a/zppy/templates/pcmdi_diags/mean_climate_plot_driver.py b/zppy/templates/pcmdi_diags/mean_climate_plot_driver.py index b866f40b..d70c1ed5 100755 --- a/zppy/templates/pcmdi_diags/mean_climate_plot_driver.py +++ b/zppy/templates/pcmdi_diags/mean_climate_plot_driver.py @@ -73,6 +73,8 @@ def load_cmip_metrics_data(cmip_file): # move highlight_models to the end for model in highlight_models: idxs = df[df.iloc[:, 0] == model].index + cmip_models.remove(model) + cmip_models.append(model) for idx in idxs: df = shift_row_to_bottom(df, idx) cmip_lib.df_dict[stat][season][region] = df @@ -623,7 +625,7 @@ def mean_climate_metrics_plot(parameter): highlight_models, file_template, figure_template, - outdir, + ptrait_fig_dir, data_version=None, watermark=False, )