Skip to contents

Highlight the location of a particular cell population on a given bi-exponential axis.

Usage

Utility_ThirdColorPlots(
  x,
  subset,
  xaxis,
  yaxis,
  zaxis,
  splitpoint = 100,
  thecolor = "red",
  sample.name,
  removestrings,
  tilesize = 0.7,
  FactorNames = NULL,
  reference = NULL
)

Arguments

x

A GatingSet Object

subset

Desired Gate of Interest

xaxis

X-axis Marker

yaxis

Y-axis Marker

zaxis

The Marker you want visible

splitpoint

Point that denotes positive and negative for that marker.

thecolor

What color should positive cells be

sample.name

The keyword that determines a specimens name

removestrings

A list of string characters to remove from the name

tilesize

Equivalent of bin, determines the height and width of the tile dots.

FactorNames

Provide factor names when splitpoint equals categorical

reference

Provide Coereba reference when splitpoint equals crossreference

Value

A ggplot object with z-axis cells highlighted from background cells

Examples


library(BiocGenerics)
library(flowCore)
library(flowWorkspace)
library(openCyto)
library(data.table)

File_Location <- system.file("extdata", package = "Luciernaga")
FCS_Files <- list.files(path = File_Location, pattern = ".fcs",
  full.names = TRUE)
Unmixed_FullStained <- FCS_Files[grep("Unmixed", FCS_Files)]
UnmixedFCSFiles <- Unmixed_FullStained[1]
UnmixedCytoSet <- load_cytoset_from_fcs(UnmixedFCSFiles[1],
  truncate_max_range = FALSE,transformation = FALSE)
UnmixedGatingSet <- GatingSet(UnmixedCytoSet)
Markers <- colnames(UnmixedCytoSet)
KeptMarkers <- Markers[-grep("Time|FS|SC|SS|Original|-W$|-H$|AF", Markers)]
MyBiexponentialTransform <- flowjo_biexp_trans(channelRange = 256,
  maxValue = 1000000,pos = 4.5, neg = 0, widthBasis = -1000)
TransformList <- transformerList(KeptMarkers, MyBiexponentialTransform)
UnmixedGatingSet <- flowWorkspace::transform(UnmixedGatingSet, TransformList)
FileLocation <- system.file("extdata", package = "Luciernaga")
UnmixedGates <- fread(file.path(path = FileLocation, pattern = 'GatesUnmixed.csv'))
UnmixedGating <- gatingTemplate(UnmixedGates)
#> Adding population:singletsFSC
#> Adding population:singletsSSC
#> Adding population:singletsSSCB
#> Adding population:nonDebris
#> Adding population:lymphocytes
#> Adding population:live
gt_gating(UnmixedGating, UnmixedGatingSet)
#> Gating for 'singletsFSC'
#> done!
#> done.
#> Gating for 'singletsSSC'
#> done!
#> done.
#> Gating for 'singletsSSCB'
#> done!
#> done.
#> Gating for 'nonDebris'
#> done!
#> done.
#> Gating for 'lymphocytes'
#> The prior specification has no effect when usePrior=no
#> Using the serial version of flowClust
#> done!
#> done.
#> Gating for 'live'
#> done!
#> done.
#> finished.

removestrings <-  c("DTR_", ".fcs")
StorageLocation <- file.path("C:", "Users", "JohnDoe", "Desktop")

SinglePlot <-  Utility_ThirdColorPlots(x=UnmixedGatingSet[1],
  subset = "live", xaxis="BUV496-A", yaxis = "Spark Blue 550-A",
  zaxis ="BUV805-A", splitpoint = "continuous", sample.name = "GROUPNAME",
  removestrings = removestrings,thecolor = "blue")
#> Splitpoint is a continuous