convexify: convexify

View source: R/tiles.R

convexifyR Documentation

convexify

Description

order coordinates based on their angle around a central point

Usage

convexify(xside, yside, indx, indy, order = FALSE)

Arguments

xside

vector of x coordinates

yside

vector of y coordinates

indx

central point x coordinate

indy

central point y coordinate

order

logical - if TRUE return order only and not the coordinates

Details

For rasterisation, the shape of the polygon must be as convex as possible. To ensure that all points are in some sense in a convex form we order them based on their polar coordinate angle.

Value

a data frame of ordered x and y coordinates.


patrickCNMartin/Vesalius documentation built on April 17, 2025, 11:31 p.m.