# NOT RUN {
f <- system.file("ex/elev.tif", package="terra")
r <- rast(f)
alt <- disaggregate(r, 10, method="bilinear")
slope <- terrain(alt, 'slope')
aspect <- terrain(alt, 'aspect')
hill <- shade(slope, aspect, 40, 270)
plot(hill, col=grey(0:100/100), legend=FALSE, mar=c(2,2,1,4))
plot(alt, col=rainbow(25, alpha=0.35), add=TRUE)
# }
Run the code above in your browser using DataLab