find_edges_3D | R Documentation |
Checks all neighbour indices in a vector c_search
for TRUE
. If all neighbours are TRUE
it is not an edge, else it is.
c_search |
Logical vector |
n |
dimensions of 3D array c(nx, ny, nz) |
logical vector if edge was found
n <- c(6L,5L,4L)
df_input <- expand.grid(
x = 1:n[1],
y = 1:n[2],
z = 1:n[3])
df_input$search <- TRUE
df_input$edge <- find_edges_3D(df_input$search, n)
df_input$color <- ifelse(df_input$edge, "blue", "black")
df_input
df_input|>
rgl::plot3d(col = df_input$color, size = 15,aspect = "iso")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.