diff --git a/reformat_scripts/obs/reformat_obs_ERA-Interim.ncl b/reformat_scripts/obs/reformat_obs_ERA-Interim.ncl index 4e06b97e89..41951f4452 100644 --- a/reformat_scripts/obs/reformat_obs_ERA-Interim.ncl +++ b/reformat_scripts/obs/reformat_obs_ERA-Interim.ncl @@ -418,11 +418,30 @@ begin fout = OUTDIR + "OBS_" + OBSNAME + "_reanaly_1_" + FIELD + \ "_" + VARS(vID) + "_" + YEAR1 + "01-" + YEAR2 + "12.nc" + ;; Add height coordinate to tas variable (required by the new backend) + if (VARS(vID).eq."tas") then + output@coordinates = "height" + end if + ;; Write variable write_nc(fout, VARS(vID), output, gAtt) delete(gAtt) delete(output) + ;; Add height coordinate to tas variable (required by the new backend) + if (VARS(vID).eq."tas") then + height = 2.d + height!0 = "ncl_scalar" + height@units = "m" + height@axis = "Z" + height@positive = "up" + height@long_name = "height" + height@standard_name = "height" + w = addfile(fout, "w") + w->height = height + delete(w) + end if + end do leave_msg(diag_script, "", 1) diff --git a/reformat_scripts/obs/reformat_obs_NCEP.ncl b/reformat_scripts/obs/reformat_obs_NCEP.ncl index 80cffbd0d2..bde5eec56c 100644 --- a/reformat_scripts/obs/reformat_obs_NCEP.ncl +++ b/reformat_scripts/obs/reformat_obs_NCEP.ncl @@ -258,11 +258,30 @@ begin fout = OUTDIR + "OBS_" + OBSNAME + "_reanaly_1_" + FIELD + \ "_" + VARS(vID) + "_" + YEAR1 + "01-" + YEAR2 + "12.nc" + ;; Add height coordinate to tas variable (required by the new backend) + if (VARS(vID).eq."tas") then + output@coordinates = "height" + end if + ;; Write variable write_nc(fout, VARS(vID), output, gAtt) delete(gAtt) delete(output) + ;; Add height coordinate to tas variable (required by the new backend) + if (VARS(vID).eq."tas") then + height = 2.d + height!0 = "ncl_scalar" + height@units = "m" + height@axis = "Z" + height@positive = "up" + height@long_name = "height" + height@standard_name = "height" + w = addfile(fout, "w") + w->height = height + delete(w) + end if + end do leave_msg(diag_script, "", 1)