is_chull: Points on Convex Hull

View source: R/chull.R

is_chullR Documentation

Points on Convex Hull

Description

Given a set of locations, this function determines which locations belongs to the convex hull (or envelope) of the set.

Usage

is_chull(x, y)

isChull(x, y)

Arguments

x

A vector of x (or longitude) coordinates.

y

A vector of y (or latitude) coordinates.

Value

A numerical vector of the same length as x and y. 0 indicates that the corresponding location is not part of the convex hull of the set. Values >0 indicates that the corresponding location is part of the convex hull, and each value corresponds to the order of the locations along the convex hull polygon.

Author(s)

Simon Garnier, garnier@njit.edu

See Also

chull_area, chull_perimeter

Examples

x <- rnorm(25)
y <- rnorm(25, sd = 3)
is_chull(x, y)


swarm-lab/swaRm documentation built on Dec. 3, 2023, 9:30 p.m.