l_layer_hull: Layer a hull for 'loon'

Description Usage Arguments Details Value Examples

View source: R/l_layer_hull.R

Description

Creates a layer which is the subset of points lying on the hull (convex or alpha) of the set of points specified.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
l_layer_hull(
  widget,
  x,
  y,
  color = "black",
  linewidth = 1,
  label = "hull",
  parent = "root",
  index = 0,
  group = NULL,
  active = TRUE,
  ...
)

Arguments

widget

'loon' widget path name as a string

x

The coordinates of x. See details

y

The coordinates of y. See details

color

the line color of each hull

linewidth

the line width

label

label used in the layers inspector

parent

parent group layer

index

of the newly added layer in its parent group

group

separate x vector or y vector into a list by group

active

a logical determining whether points appear or not (default is TRUE for all points). If a logical vector is given of length equal to the number of points, then it identifies which points appear (TRUE) and which do not (FALSE).

...

other arguments to modify l_layer_line.

Details

Coordinates: the x or y can be a list or a vector.

Value

an l_layer widget

Examples

1
2
3
4
if(interactive()) {
p <- l_plot(iris, color = iris$Species)
l <- l_layer_hull(p, group = iris$Species)
}

loon.tourr documentation built on Oct. 27, 2021, 5:09 p.m.