cyto_save: Write samples to FCS files in new folder or save GatingSet

View source: R/cyto-helpers.R

cyto_saveR Documentation

Write samples to FCS files in new folder or save GatingSet

Description

Write samples to FCS files in new folder or save GatingSet

Usage

cyto_save(x, ...)

## S3 method for class 'GatingSet'
cyto_save(
  x,
  parent = NULL,
  split = FALSE,
  names = NULL,
  save_as = NULL,
  inverse = FALSE,
  trans = NULL,
  ...
)

## S3 method for class 'GatingHierarchy'
cyto_save(
  x,
  parent = NULL,
  split = FALSE,
  names = NULL,
  save_as = NULL,
  inverse = FALSE,
  trans = NULL,
  ...
)

## S3 method for class 'flowSet'
cyto_save(
  x,
  split = FALSE,
  names = NULL,
  save_as = NULL,
  inverse = FALSE,
  trans = NULL,
  ...
)

## S3 method for class 'flowFrame'
cyto_save(
  x,
  split = FALSE,
  names = NULL,
  save_as = NULL,
  inverse = FALSE,
  trans = NULL,
  ...
)

Arguments

x

object of class flowFrame, flowSet, GatingHierarchy or GatingSet.

...

not in use.

parent

name of the parent population to extract when a GatingHierarchy or GatingSet object is supplied. If the name of the parent is supplied the samples will be written to FCS files in the specified save_as directory. Otherwise the entire GatingSet or GatingHierarchy will be saved to the specified save_as directory.

split

logical indicating whether samples merged using cyto_merge_by should be split prior to writing FCS files, set to FALSE by default.

names

original names of the samples prior to merging using cyto_merge_by, only required when split is TRUE. These names will be re-assigned to each of split flowFrames.

save_as

name of the folder to which the written FCS files should be saved, set to NULL by default to save the files to the current working directory. To prevent files being overwritten, it is recommended that save_as directory not be manually created before running cyto_save.

inverse

logical indicating whether the data should be inverse transformed prior to writing FCS files, set to FALSE by default. Inverse transformations of flowFrame or flowSet objects requires passing of transformers through the trans argument.

trans

object of class transformerList containing the transformation definitions applied to the supplied data. Used internally when inverse_transform is TRUE, to inverse the transformations prior to writing FCS files.

Value

list of flowFrames containing the data that was saved to the FCS files.

Author(s)

Dillon Hammill, Dillon.Hammill@anu.edu.au

See Also

cyto_split

Examples


## Not run: 
# Load in CytoExploreRData to access data
library(CytoExploreRData)

# Activation flowSet
fs <- Activation

# Save each flowFrame to file
cyto_save(fs, save_as = "Samples")

## End(Not run)


DillonHammill/CytoExploreR documentation built on March 2, 2023, 7:34 a.m.