Skip to content

Instantly share code, notes, and snippets.

View wiesehahn's full-sized avatar

Jens Wiesehahn wiesehahn

View GitHub Profile

Get elevation data from Copernicus 30m or GEBCO 2023. Run get_elev(rast) with any raster to get elevation data from online.

The function chooses which source based on the distance across the centre cell of the query raster, if that is less than 'threshold' it goes for the 30m SRTM source "cop30".

Requires in-dev terra, see install instructs in code below

  library(terra)
#> terra 1.7.41