View source: R/otherTempExtremes.R
otherTempExtremes | R Documentation |
Generates max temp of the coldest month, min temp of the warmest month, mean temp of the coldest month, mean temp of the warmest month.
otherTempExtremes(meantempStack, mintempStack, maxtempStack)
meantempStack |
SpatRaster of monthly mean temperature |
mintempStack |
SpatRaster of monthly min temperature |
maxtempStack |
SpatRaster of monthly max temperature |
SpatRaster of maxTempColdest, minTempWarmest, meanTempColdest, meanTempWarmest, in same units as input rasters.
Pascal Title
# Find example rasters
rasterFiles <- list.files(system.file('extdata', package='envirem'), full.names=TRUE)
env <- rast(rasterFiles)
# identify appropriate layers
tmean <- grep('tmean', names(env))
tmin <- grep('tmin', names(env))
tmax <- grep('tmax', names(env))
tmean <- env[[tmean]]
tmin <- env[[tmin]]
tmax <- env[[tmax]]
# calculate temperature extremes
otherTempExtremes(tmean, tmin, tmax)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.