View source: R/genCompositions.R
genCompositions | R Documentation |
genCompositions
combines a series of satellite images to create compositions.
genCompositions(rstack, by, fun, n, by.days = FALSE, verbose = FALSE, ...)
rstack |
a |
by |
character argument. Accepts |
fun |
the function used to create the composite, such as |
n |
number of images combined in the aggregation. Only required if
|
by.days |
logical argument. If |
verbose |
logical argument. If |
... |
arguments for nested functions:
|
The layer of the composite image takes its name from the first image used in the composition.
genCompositions
reduces the number of images but improves the total
quality of the time-series by removing cloulds and outliers. One widespread
compositing technique is the maximum value composition (MVC). This technique
allocates in each pixel of the composite the maximum value (fun = max) that
the pixel reaches during a time period (n
, by.days = TRUE
).
a RasterStack
with the time series of the composite images.
# loading NDVI images of Navarre data("ex.ndvi.navarre") # Ploting the images: clouds are found genPlotGIS(ex.ndvi.navarre) # the first composite image is made with images 1, 2 and 3, # and the second composite image is made with images 4, 5 and 6 composite.NDVI.a <- genCompositions(rstack = ex.ndvi.navarre, n = 3, fun = max) genPlotGIS(composite.NDVI.a) # when by.days=TRUE, the first composite image is made with images 1, 2 and 3, # the second with image 4, and the third with images 5 and 6. composite.NDVI.3a <- genCompositions(rstack = ex.ndvi.navarre, n = 3, by.days = TRUE, fun = max) # Check that the clouds were removed genPlotGIS(composite.NDVI.3a)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.