Skip to contents

Creates a map of a sea-mask raster and overlays coastlines for geographical context.

Usage

plot_seamask(seamask, title = "Coastline and bird distribution")

Arguments

seamask

A raster::RasterLayer object containing sea-mask data, such as the object returned by get_example_seamask().

title

Character string giving the plot title. Defaults to "Coastline and sea mask".

Value

A ggplot2::ggplot() object showing land, sea, and the coastline.

Details

Cells containing missing values are classified as land, while cells containing non-missing values are classified as sea.

The coastline data supplied with the package are transformed to the coordinate reference system of seamask before plotting.

Examples

# Load and plot the example sea mask
seamask <- get_example_seamask()
plot_seamask(seamask)