Plot 3D graph layouts
Plot3DGraph.Rd
Plot a 3D component graph layout computed with ComputeLayout
and
color nodes by a marker.
Arguments
- object
A
Seurat
object- cell_id
ID of component to visualize
- marker
Name of marker to color the nodes by
- assay
Name of assay to pull data from
- layout_method
Select appropriate layout previously computed with
ComputeLayout
- project
Project the nodes onto a sphere. Default FALSE
- aspectmode
Set aspect ratio to one of "data" or "cube". If "cube", this scene's axes are drawn as a cube, regardless of the axes' ranges. If "data", this scene's axes are drawn in proportion with the axes' ranges.
Default "data"
- colors
Color the nodes expressing a marker. Must be a character vector with at least two color names.
- showgrid
Show the grid lines. Default TRUE
- log_scale
Convert node counts to log-scale with
logp
- node_size
Size of nodes
- show_Bnodes
Should B nodes be included in the visualization? This option is only applicable to bipartite graphs.
- ...
Additional parameters passed to
plot_ly
Examples
library(pixelatorR)
pxl_file <- system.file("extdata/five_cells",
"five_cells.pxl",
package = "pixelatorR"
)
seur <- ReadMPX_Seurat(pxl_file)
#> ✔ Created a 'Seurat' object with 5 cells and 80 targeted surface proteins
seur <- LoadCellGraphs(seur, cells = colnames(seur)[5])
#> → Loading CellGraphs for 1 cells from sample 1
#> ✔ Successfully loaded 1 CellGraph object(s).
seur <- ComputeLayout(seur, layout_method = "pmds", dim = 3)
#> ℹ Computing layouts for 1 graphs
Plot3DGraph(seur, cell_id = colnames(seur)[5], marker = "CD50", layout_method = "pmds_3d")