This function splits the convex hull in two along an input vertical or horizontal line.
splitInTwo(
p,
pointsDF,
axisIntersect,
pointCoords,
borderPoints,
legendLabs = paste0("Group ", seq(2)),
alpha = 0.5
)A ggplot object showing the hull split in two parts along the input line.
A ggplot object representing the hull.
A data frame with the x and y coordinates of the points.
The coordinate where the vertical or horizontal line intersects the relevant axis.
The coordinates of the input points on the axis perpendicular to the input border line.
The points where the border line intersects the convex hull.
Legend labels.
Opaqueness level.