pastclim_rast: Read a raster for pastclim

pastclim_rastR Documentation

Read a raster for pastclim

Description

This function is a wrapper around terra::rast(), with additional logic to correctly import time for vrt datasets (time is stored as custom metadata in pastclim-generated vrt files)

Usage

pastclim_rast(
  x,
  bio_var_orig,
  bio_var_pastclim,
  var_longname = NULL,
  var_units = NULL
)

Arguments

x

filename of the raster

bio_var_orig

the variable name as present in the file

bio_var_pastclim

the variable name as used by pastclim (thus allowing us to rename the variable)

Value

a terra::SpatRaster


EvolEcolGroup/pastclim documentation built on Nov. 8, 2024, 5:21 a.m.