
Plot seasonal SST vs. MMM with bleaching status
plot_sst_timeseries.RdProduce a seasonal plot (Nov of targetyear-1 to Jul of targetyear)
showing SST relative to the site MMM and MMM+1 degrees C threshold, with a
bottom bar indicating NOAA-style bleaching alert status derived from
hotspots and dhw.
Usage
plot_sst_timeseries(
input,
startdate,
enddate = NULL,
title = "",
legend_position = c(0.95, 0.4)
)Arguments
- input
A list containing at least these
terra::SpatRasterelements:sst– daily sea-surface temperature (with time dimension)mmm– maximum monthly mean (single-layer raster or single cell)hotspots– daily hotspots (same time assst)dhw– daily Degree Heating Weeks (same time assst)
Typically this is the output from your climatology pipeline.
- startdate
start date for timeseries
- enddate
end date for timeseries
- title
legend title
- legend_position
legend position from ggplot standard
Examples
if (FALSE) { # \dontrun{
p <- plot_sst_timeseries(eyrie_climatology, startdate = "2023-11-01", enddate = "2026-02-28")
print(p)
} # }