Description Usage Arguments Value Examples
View source: R/goesaodc_plotScanSpdf.R
Plot a GOES scan SPDF
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | goesaodc_plotScanSpdf(
spdf = NULL,
bbox = bbox_CONUS,
pointSize = 0.5,
pointShape = 15,
pointAlpha = NULL,
paletteColors = c("#FFFFB2", "#BD0026"),
naColor = "gray50",
paletteName = "YlOrRd",
paletteBreaks = NULL,
legendLimits = NULL,
includeMap = FALSE,
zoom = NULL,
stateCodes = NULL,
title = NULL,
legendTitle = NULL
)
|
spdf |
|
bbox |
Bounding box for the visible region. Defaults to CONUS. |
pointSize |
Size of plot points. Defaults to 0.5. |
pointShape |
Shape of the plot points (index). Defaults to 15 (filled square). |
pointAlpha |
Transparency of the points. If not explicitly defined, it
will default to 1.0 when |
paletteColors |
Vector of colors defining the gradient for the color
legend. Will be ignored if |
naColor |
Color to shade cells with NA AOD values. |
paletteName |
Name of an RColorBrewer palette. Defaults to 'YlOrRd'. |
paletteBreaks |
Vector of AOD values to use as palette breaks. |
legendLimits |
Upper and lower values for the color legend. Setting this
guarantees that the legend will appear even if the SPDF has nothing but
|
includeMap |
Logical flag determining whether to draw a topographic map image under the points. Since the image is Mercator projected, the plot coordinate system will be Mercator projected to match. Defaults to FALSE. |
zoom |
Zoom level of the topographic map, if it is included. Must be an integer from 1 to 15. |
stateCodes |
Codes of state outlines to draw. |
title |
Title of the plot. |
legendTitle |
Title of the plot legend. |
ggplot
of a SpatialPointsDataFrame
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | library(MazamaSatelliteUtils)
library(MazamaSpatialUtils)
setSatelliteDataDir("~/Data/Satellite")
setSpatialDataDir("~/Data/Spatial")
loadSpatialData("NaturalEarthAdm1")
bboxKingcadeFire <- c(-124, -120, 36, 39)
scanFile <- goesaodc_listScanFiles(
satID = "G17",
datetime = "2019-10-27 10:00",
timezone = "America/Los_Angeles"
)
scanSpdf <- goesaodc_createScanSpdf(
filename = scanFile,
bbox = bboxKingcadeFire
)
emptyScanSpdf <- goesaodc_createScanSpdf(
filename = "OR_ABI-L2-AODC-M6_G17_s20202522231174_e20202522233547_c20202522235327.nc",
bbox = bboxKingcadeFire
)
# Plot SPDF for a scan
goesaodc_plotScanSpdf(
spdf = scanSpdf,
bbox = bboxKingcadeFire,
paletteBreaks = c(-Inf, 0, 1, 2, 3, 4, 5, Inf),
includeMap = TRUE,
zoom = 8,
stateCodes = "CA",
title = "Kincade fire"
)
# Plot SPDF for a scan filled with NA AOD values
goesaodc_plotScanSpdf(
spdf = emptyScanSpdf,
bbox = bboxKingcadeFire,
legendLimits = c(-1, 6),
stateCodes = "CA"
)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.