get_bins | R Documentation |
Get corresponding bin number, latitude, longitude and depth for Pan-Canadian Grid or subregions. These are vectors of bin/lat/lon/bathymetry that have already been generated for easier access.
get_bins(region = "pancan", resolution = "4km", variables = "all")
region |
String, either "pancan", "nwa", "nep", or "gosl" |
resolution |
String, either "4km" or "9km". |
variables |
String with columns: blank or "all" for all columns, or a subset of c("bin","longitude","latitude","bathymetry") |
Data frame with columns of bin, longitude, latitude, bathymetry
library(dplyr)
library(ggplot2)
library(oceancolouR)
pancan_bins_4km <- get_bins()
# Map of the North West Atlantic bin bathymetry
get_bins(region = "nwa", resolution = "9km") %>%
ggplot(aes(x = longitude, y = latitude, colour = bathymetry)) +
geom_point(size = 0.5) +
scale_colour_gradientn(colours = pals::ocean.deep(30))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.