Add tensor visualisation to a plotly graph of type mesh3d

show_tensors(p, cellGraph, tensor_name, scale = 1)

Arguments

p

A plot created with plotlyMesh() function.

cellGraph

A cell graph created with read_cellGraph().

tensor_name

The name of the tensor variable from cell graph to visualise.

scale

Shorten or lengthen the line for visualisation.

Value

a plotly graph

Examples

# NOT RUN {
myMesh <- readRDS(system.file("extdata",
 "mgx/2013-02-12_LTi6B_dis_A_T0_cells_minW1_normalMesh_full.rds",
  package = "cellviz3d"))
myCellGraph <- readRDS(system.file("extdata",
 "mgx/2013-02-12_LTi6B_dis_A_T0_cells_minW1_cellGraph_full.rds",
  package = "cellviz3d"))

 # With a uniform mesh color:
p <- plotlyMesh(meshExample = myMesh,
meshCellcenter = meshCellcenter) %>%
layout(scene =
list(aspectmode = "data"))

show_tensors(p, myCellGraph,
tensor_name = "CellAxiscurv10microns",
scale = 50)
# }