update_focal | R Documentation |
Update current focal for the next iteration.
update_focal(old_focal, new_rasterized, extent, mw)
old_focal |
Focal obtained from |
new_rasterized |
Output obtained from |
extent |
Extent of the cells corresponding to the coordinates with the
highest concentration for the current iteration. Extent is output from
|
mw |
Moving window obtained from |
Spatial extent refers to the geographic area covered by a spatial dataset. It defines the boundaries in terms of its geographic coordinates (north, east, south, west).
An focal is updated by the following steps:
The extent of the cells corresponding to the coordinates with the highest concentration (xmin, xmax, ymin, ymax) is determined.
A buffer of size two times the radius plus the cell size around this extent. All cells within this new extent will impact the focal values.
Subset (crop) the rasterized data to include only the cells within this new extent. Perform focal calculations only for these new cells.
As the focal values of the cells near the borders may be inflated, crop the result again to include only the cells within a radius of the original extent.
Merge this updated focal with the previous focal object.
Martin Haringa
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.