# \donttest{
file_path <- system.file("extdata/cyl_temp.tif", package = "tidyterra")
library(terra)
temp <- rast(file_path)
library(ggplot2)
autoplot(temp)
# With a tile
tile <- system.file("extdata/cyl_tile.tif", package = "tidyterra") %>%
rast()
autoplot(tile)
# With coltabs
ctab <- system.file("extdata/cyl_era.tif", package = "tidyterra") %>%
rast()
autoplot(ctab)
# With vectors
v <- vect(system.file("extdata/cyl.gpkg", package = "tidyterra"))
autoplot(v)
v %>% autoplot(aes(fill = cpro)) +
geom_spatvector_text(aes(label = iso2)) +
coord_sf(crs = 25829)
# }
Run the code above in your browser using DataLab