Plot_coordinates {PopGenHelpR} | R Documentation |
A function to plot coordinates on a map.
Description
A function to plot coordinates on a map.
Usage
Plot_coordinates(
dat,
col = c("#A9A9A9", "#000000"),
size = 3,
Lat_buffer = 1,
Long_buffer = 1,
Latitude_col = NULL,
Longitude_col = NULL
)
Arguments
dat |
Data frame or character string that supplies the input data. If it is a character string, the file should be a csv. The coordinates of each row should be indicated by columns named Longitude and Latitude. Alternatively, see the Latitude_col and Longitude_col arugments. |
col |
Character vector indicating the colors you wish to use for plotting, two colors are allowed. The first color will be the fill color, the second is the outline color. For example, if I want red points with a black outline I would set col to col = c("#FF0000", "#000000"). |
size |
Numeric. The size of the points to plot. |
Lat_buffer |
Numeric. A buffer to customize visualization. |
Long_buffer |
Numeric. A buffer to customize visualization. |
Latitude_col |
Numeric. The number of the column indicating the latitude for each sample. If this is not null, PopGenHelpR will use this column instead of looking for the Latitude column. |
Longitude_col |
Numeric. The number of the column indicating the longitude for each sample. If this is not null, PopGenHelpR will use this column instead of looking for the Longitude column. |
Value
A ggplot object.
Author(s)
Keaka Farleigh
Examples
data("HornedLizard_Pop")
Test <- Plot_coordinates(HornedLizard_Pop)