R/cyto_stats_compute-methods.R
cyto_stats_compute-flowSet-method.Rd
Calculate and export flow cytometry statistics for a flowSet.
# S4 method for flowSet cyto_stats_compute(x, channels = NULL, trans = NULL, stat = "median", density_smooth = 1.5)
x | object of class |
---|---|
channels | names of of channels for which statistic should be calculated, set to all channels by default. |
trans | object of class
|
stat | name of the statistic to calculate, options include
|
density_smooth | smoothing parameter passed to
|
library(CytoRSuiteData) # Load in samples fs <- Activation # Apply compensation fs <- compensate(fs, fs[[1]]@description$SPILL) # Transform fluorescent channels trans <- estimateLogicle(fs[[4]], cyto_fluor_channels(fs)) fs <- transform(fs, trans) # Compute statistics cyto_stats_compute(fs, channels = c("Alexa Fluor 488-A", "PE-A"), trans = trans, stat = "median" )#> [[1]] #> Alexa Fluor 488-A PE-A #> Activation1.fcs 284.4327 314.0881 #> Activation2.fcs 284.7291 327.8888 #> Activation3.fcs 298.0716 332.8367 #> Activation4.fcs 299.8310 330.3305 #>#> [[1]] #> FSC-A FSC-H FSC-W SSC-A SSC-H SSC-W #> Activation1.fcs 40932.46 35831.14 74866.43 23625.73 21173.17 73127.03 #> Activation2.fcs 42142.24 36807.03 75035.33 23553.21 21067.52 73268.37 #> Activation3.fcs 41301.94 36032.20 75120.54 23031.80 20548.64 73455.55 #> Activation4.fcs 41823.06 36219.29 75675.59 23470.95 20743.85 74151.72 #> Alexa Fluor 488-A PE-A PE-Texas Red-A 7-AAD-A PE-Cy7-A #> Activation1.fcs 394.5147 652.2790 131.1220 297.1671 38.70415 #> Activation2.fcs 394.9469 672.1038 113.9421 324.6894 36.76597 #> Activation3.fcs 406.0882 667.9965 106.2362 373.6129 35.16081 #> Activation4.fcs 411.3127 664.3363 105.8318 469.0054 35.45777 #> Alexa Fluor 405-A Alexa Fluor 430-A Qdot 605-A #> Activation1.fcs 1147.5487 756.7397 1375.884 #> Activation2.fcs 1026.3656 670.3747 1271.674 #> Activation3.fcs 987.3453 654.0498 1276.558 #> Activation4.fcs 972.1674 646.6824 1274.180 #> Alexa Fluor 647-A Alexa Fluor 700-A APC-Cy7-A Time #> Activation1.fcs 1313.115 208.9713 92.58347 2139.517 #> Activation2.fcs 1299.822 216.8302 92.17633 2001.497 #> Activation3.fcs 1479.374 219.8525 95.43460 2021.625 #> Activation4.fcs 1570.542 213.8582 92.73215 2111.609 #>#> [[1]] #> count #> Activation1.fcs 50000 #> Activation2.fcs 50000 #> Activation3.fcs 50000 #> Activation4.fcs 50000 #>