# NOT RUN {
## The following example require to have downloaded
## a large elevation raster with the function getelev()
## and will therefore not run unless you type:
## example(elevraster, run.dontrun=TRUE)
# }
# NOT RUN {
### CREATING THE OBJECT elevraster
## download the tif file (ca. 700 Mb):
## (see ?getelev for details on how to get the tif file)
# getelev()
## convert the tif into R raster format:
library(raster)
elevationrasterbig <- raster("gmted2010_30mn.tif")
## create the highly agregated elevation raster
## (90 sec on one of our computers):
elevraster <- relevate(
elevationrasterbig,
aggregation.factor=100)
# }
# NOT RUN {
# }
Run the code above in your browser using DataLab