cellVertices {tessellation} | R Documentation |
Vertices of a bounded cell
Description
Get all vertices of a bounded cell, without duplicates.
Usage
cellVertices(cell, check.bounded = TRUE)
Arguments
cell |
a bounded Voronoï cell |
check.bounded |
Boolean, whether to check that the cell is bounded;
set to |
Value
A matrix, each row represents a vertex.
Examples
library(tessellation)
d <- delaunay(centricCuboctahedron())
v <- voronoi(d)
cell13 <- v[[13]]
isBoundedCell(cell13) # TRUE
library(rgl)
open3d(windowRect = c(50, 50, 562, 562))
invisible(lapply(cell13[["cell"]], function(edge){
edge$plot(edgeAsTube = TRUE, tubeRadius = 0.025, tubeColor = "yellow")
}))
cellvertices <- cellVertices(cell13)
spheres3d(cellvertices, radius = 0.1, color = "green")
[Package tessellation version 2.3.0 Index]