View source: R/tmap_CreateBasemap.R
tmap_CreateBasemap | R Documentation |
This function creates a basemap layer for maps based on the tmap package.
tmap_CreateBasemap(
layer.land = getPackagedLayer("Alaska"),
layer.bathym = getPackagedLayer("ShelfBathymetry"),
final.crs = get_crs("WGS84"),
bbox = getStandardBBox("EBS"),
colors.bg = "white",
colors.land = "grey85",
colors.bathym = "darkblue",
alpha.bathym = 1,
points.size = 0.01
)
layer.land |
|
layer.bathym |
|
final.crs |
|
bbox |
|
colors.bg |
|
colors.land |
|
colors.bathym |
|
alpha.bathym |
|
points.size |
|
The basemap contains a land layer (polygons) and a bathymetry layer (lines).
Uses getPackagedLayer()
or readShapefile()
to create the
land and bathymetric layers. If bbox
is NULL, then the
bounding box for the land layer is used as the bounding box for the basemap.
The final coordinate reference system (final.crs
) can be any object that
can be converted to a sf::st_crs()
object using get_crs()
.
The bounding box (bbox
) can be any object that can be converted
to a sf::bbox
using getBBox()
.
basemap layer based on the tmap package
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.