sectors_segmentation: Do sectors segmentation

View source: R/sectors_segmentation.R

sectors_segmentationR Documentation

Do sectors segmentation

Description

Segment a hemispherical view by slicing the azimuth angle from zero to 360º in equals intervals.

Usage

sectors_segmentation(a, angle_width, return_angle = FALSE)

Arguments

a

SpatRaster built with azimuth_image().

angle_width

Numeric vector of length one. Angle in degrees able to divide the angle range into a whole number of segments.

return_angle

Logical vector of length one. If it is FALSE, all the pixels that belong to a segment are labeled with an ID number. Otherwise, the angle mean of the segment is assigned to the pixels.

Value

An object from the class SpatRaster with segments shaped like pizza slices.

See Also

Other Segmentation Functions: chessboard(), mask_hs(), mask_sunlit_canopy(), polar_qtree(), qtree(), rings_segmentation(), sky_grid_segmentation()

Examples

z <- zenith_image(600, lens())
a <- azimuth_image(z)
sectors <- sectors_segmentation(a, 15)
plot(sectors == 1)

rcaiman documentation built on Nov. 15, 2023, 1:08 a.m.