oisst_window_load: Access OISST via Data Window of lat/lon/time

View source: R/oisst_mainstays_data_access.R

oisst_window_loadR Documentation

Access OISST via Data Window of lat/lon/time

Description

Returns a list of OISST raster stacks that has been clipped to the desired lat/lon/time extent. Each list element is named according to year, and contains all daily measurements within the desired window of time, and clipped to the desired lat/lon extent.

Useful for loading OISST observations from box, but only for a particular area and/or time.

Usage

oisst_window_load(
  data_window,
  anomalies = FALSE,
  climate_ref = "1982-2011",
  box_location = "default_boxpath|cloudstorage"
)

Arguments

data_window

dataframe with columns for lat, lon, & time indicating the extent of the data desired.

anomalies

Boolean indication of whether to return observed sst or anomalies. Default = TRUE.

climate_ref

String indicating the climatology to use for anomaly option "yyyy-yyyy" format, options are "1982-2011" or "1991-2020"

box_location

String indicating value to pass to 'boxpath_switch'

Value

Raster stack of OISSTv2 data using desired dimensions to crop

Examples

#not run
# oisst_path <- box_path(box_group = "res", subfolder = "OISST/oisst_mainstays")
# data_window <- data.frame(lon = c(-72, -65),
#                           lat = c(42,44),
#                           time = as.Date(c("2016-08-01", "2020-12-31")))


gulfofmaine/gmRi documentation built on Jan. 26, 2025, 5:12 a.m.