calcindices_temp | R Documentation |
This routine replicates the primary mean temperature and area-below-x indices as found in the cold_pool_index data frame, but allows for user-specified variations.
calcindices_temp(
datafile,
maskpoly,
select_years = NULL,
cell_resolution = 5000,
method = "ste",
proj_crs = NULL,
threshold = c(-1, 0, 1, 2),
bbox = NULL,
bottomvar = "gear_temperature",
surfacevar = "surface_temperature"
)
datafile |
Full filename of .csv file holding point-sampled surface and bottom temperature data |
maskpoly |
String specifying masking polygon from akgfmaps::get_base_layers, or simple feature object to use as masking polygon |
select_years |
vector of years for which indices will be calculated |
cell_resolution |
resolution (m) to use for interpolation raster |
method |
fitting method to use for interpolation (see data2raster fittype parameter for options) |
proj_crs |
CRS to use for interpolation, or NULL to use coldpool:::ebs_proj_crs |
threshold |
vector of temperature threshold values (deg C) for which area-less-than-x indices will be calculated |
bbox |
Bounding box to use for interpolated raster (see data2raster) |
bottomvar |
Name of bottom temperaure variable column in the datafile, or NULL to skip calculation of bottom temperature metrics |
surfacevar |
Name of surface temperaure variable column in the datafile, or NULL to skip calculation of surface temperature metrics |
data frame with the following column YEAR: year of indices MEAN_GEAR_TEMPERATURE: mean interpolated and masked bottomvar MEAN_SURFACE_TEMPERATURE: mean interpolated and masked surfacevar MEAN_BT_LT100M: mean interpolated bottomvar within the intersection of the <100m survey strata and masked region AREA_LTE_X: total area (km^2) where temperature is less than X deg C
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.