PlotLabels: PlotLabels

View source: R/5_plotFunctions.R

PlotLabelsR Documentation

PlotLabels

Description

Plot labels for each cluster

Usage

PlotLabels(
  fsom,
  labels,
  maxNodeSize = 0,
  textSize = 3.88,
  textColor = "black",
  ...
)

Arguments

fsom

FlowSOM object, as generated by FlowSOM

labels

A vector of labels for every node.

maxNodeSize

Determines the maximum node size. Default is 0.

textSize

Size for geom_text. Default (=3.88) is from geom_text.

textColor

Color for geom_text. Default = black.

...

Additional arguments to pass to PlotFlowSOM

Details

Plot FlowSOM grid or tree, with in each node a label. Especially useful to show metacluster numbers

Value

Nothing is returned. A plot is drawn in which each node is represented by a label.

See Also

PlotStars, PlotVariable, PlotFlowSOM, PlotMarker, PlotNumbers, PlotPies, QueryStarPlot, PlotSD

Examples

# Read from file, build self-organizing map and minimal spanning tree
fileName <- system.file("extdata", "68983.fcs", package="FlowSOM")
ff <- flowCore::read.FCS(fileName)
ff <- flowCore::compensate(ff, flowCore::keyword(ff)[["SPILL"]])
ff <- flowCore::transform(ff,
         flowCore::transformList(colnames(flowCore::keyword(ff)[["SPILL"]]),
                                flowCore::logicleTransform()))
flowSOM.res <- FlowSOM(ff,
                       scale = TRUE,
                       colsToUse = c(9, 12, 14:18),
                       nClus = 10,
                       seed = 1)

# Plot the node IDs
PlotLabels( flowSOM.res, 
            flowSOM.res$metaclustering)


saeyslab/FlowSOM documentation built on July 6, 2024, 10:59 a.m.