Learn R Programming

aelab (version 1.1.0)

plot_map_taiwan: plot_map_taiwan

Description

Plot sampling sites on a map of Taiwan with a north arrow and scale bar.

Usage

plot_map_taiwan(
  long,
  lat,
  names,
  color = "darkgrey",
  textsize = 5,
  basesize = 16,
  shape_type = 22
)

Value

A ggplot object (also printed to the active device).

Arguments

long

Numeric vector of longitudes.

lat

Numeric vector of latitudes.

names

Character vector of site labels (same length as long).

color

Fill colour for site markers. Default "darkgrey".

textsize

Size for annotation and point labels. Default 5.

basesize

Base font size for the map theme. Default 16.

shape_type

ggplot2 point shape number. Default 22 (filled square).

Examples

Run this code
if (FALSE) {
plot_map_taiwan(
  long = c(120.2, 121.5),
  lat  = c(22.9, 24.1),
  names = c("Site A", "Site B")
)
}

Run the code above in your browser using DataLab