Description Usage Arguments Details Value Author(s) See Also Examples
View source: R/create_star_click.R
Create a Star by clicking on a base raster
1 2 | create_star_click(BaseRaster, BeamWidth = 1000, BeamLength = 50000,
NSegments = 50, NBeams = 8)
|
BaseRaster |
a RasterLayer to be clicked on |
BeamWidth |
width of each beam in meters |
BeamLength |
length of each beam in meters |
NSegments |
number of segments of each beam |
NBeams |
the number of beams of the star |
This function plots a BaseRaster
and, on click()
, creates a Star object around the clicked point.
It consists of NBeams
times NSegments
equally sized polygons of length BeamLength/NSegments
and width BeamWidth
,
arranged in NBeams
equally spaced beams of length Beamlength
.
The returned Star is a SpatialPolygonsDataFrame and takes the CRS of the BaseRaster
.
It contains a field "OverallId" which contains unique IDs for each segment, the first 6 numbers indicating the beam, the latter 6 numbers indicating the segment.
SpatialPolygonsDataframe
Johannes Mast
1 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.