From 14b80696e354dbe25d4e94f97a1a92bad0842690 Mon Sep 17 00:00:00 2001 From: "Adam R. Jensen" <39184289+AdamRJensen@users.noreply.github.com> Date: Fri, 7 Aug 2026 11:54:18 +0200 Subject: [PATCH] Add missing DNI messages to closure plots Expanded the list of axes to include 'sun2' for DNI message and added a message for axes where DNI is not available. --- src/solarpy/plotting/multiplot.py | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/src/solarpy/plotting/multiplot.py b/src/solarpy/plotting/multiplot.py index af687a6..d87a494 100644 --- a/src/solarpy/plotting/multiplot.py +++ b/src/solarpy/plotting/multiplot.py @@ -693,7 +693,8 @@ def multiplot(times, data, meta, horizon=None, google_api_key=None, figsize=(24, # Add message to plots if DNI was calculated from GHI and DHI if not has_dni: - for ax in [axes["line"][1], axes["heatmap"][1], axes["mid_l"][1], axes["mid_r"][1], axes["sun2"]]: + for ax in [axes["line"][1], axes["heatmap"][1], axes["mid_l"][1], axes["mid_r"][1], + axes["sun2"]]: ax.text( 0.97, 0.97, @@ -703,5 +704,14 @@ def multiplot(times, data, meta, horizon=None, google_api_key=None, figsize=(24, color="black", transform=ax.transAxes, ) - + for ax in [axes["ts_scatter"][1], axes["mid_l"][3], axes["mid_r"][3]]: + ax.text( + 0.5, + 0.5, + "DNI not available.", + ha="center", + va="bottom", + color="black", + transform=ax.transAxes, + ) return fig, axes