Description Usage Arguments Value Examples
View source: R/visualizations.R
Plots the ctryNlData in various plot styles including line, box and density plot using ggplot2. If ctryData is not provided the subsequent parameters will need to be supplied so thta getCtryNlData can be used to retrieve the data prior to plotting.
1 2 3 4 5 6 7 8 |
ctryData |
data.frame If provided the plot will use data from it rather than retrieving it. If not available the follow parameters are required to retrieve the data using getCtryNlData. It is assumed that the ctryData data.frame is in the same format as the output from getCtryNlData i.e. admin cols first, an area column, followed by the stat columns. In future it may be possible to supply a custom data.frame and direct the function on which columns to find the particular data. |
admLevelFilters |
|
ctryCode |
|
admLevel |
|
nlType |
|
configName |
character the config shortname of raster being processed |
extension |
character the extension of raster being processed |
multiTileStrategy |
character How to handle multiple tiles per nlPeriod |
multiTileMergeFun |
character The function to use to merge tiles |
removeGasFlaresMethod |
character The method to use to perform gas flare removal or NULL to disable |
nlPeriod |
|
nlStats |
the statistics to calculate. If not provided will calculate
the stats specified in |
downloadMethod |
The method used to download polygons and rasters |
cropMaskMethod |
|
extractMethod |
("rast" or "gdal") Whether to use rasterize or gdal-based functions to crop and mask the country rasters |
gadmVersion |
The GADM version to use |
gadmPolyType |
The format of polygons to download from GADM |
custPolyPath |
Alternative to GADM. A path to a custom shapefile zip |
None
1 2 3 4 5 6 | #calculate only the sum of monthly VIIRS radiances for Dec 2014 using gdal
#for both cropMask and extraction for KEN
## Not run:
Rnightlights:::processNLCountry("KEN", "KEN_adm2", "VIIRS.M", "201412", "gdal", "gdal", "sum")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.