plot_pancan | R Documentation |
Given a vector of data from a binned ocean colour file, plot it on a raster with coastlines.
plot_pancan(
vec,
region = "pancan",
ext = c(xmn = -147, xmx = -41, ymn = 39, ymx = 86),
resolution = "4km",
limits = NULL
)
vec |
Numeric vector of data (must be in the same order as the the bins vector of the same resolution, whether pancan, nwa, nep, or gosl - see details). |
region |
String, either "pancan", "nwa", "nep", or "gosl" |
ext |
Named vector containing the boundaries of the resulting grid. |
resolution |
String, either "4km" or "9km". |
limits |
Limits of the colour scale (numeric vector, length 2). |
This is used to get a quick look at a file from the panCanadian dataset, before manipulating the data. When the data is loaded, it's in vector format and in the same order as the bin vectors pancan_bins_4km, nwa_bins_4km, etc...
Raster containing variable values with coastlines.
# This is an example file with data in the same format as in a panCanadian dataset file.
data("example01_A2018252.L3b_DAY_CHL_POLY4_NWA")
dat <- example01_A2018252.L3b_DAY_CHL_POLY4_NWA
lon_lim <- lon_bounds[["NWA"]]
lat_lim <- lat_bounds[["NWA"]]
plot_pancan(log10(dat), region="nwa", ext=c(range(lon_lim),range(lat_lim)))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.