Skip to contents

Checks whether the control file used to define the single-stained control setup for AutoSpectral conforms to expectations and follows rules required for successful running of AutoSpectral.

Usage

validate.control.file(
  control.dir,
  control.def.file,
  asp,
  min.event.warning,
  min.event.error,
  legacy = FALSE,
  allow.duplicate.controls = FALSE
)

Arguments

control.dir

File path to the single-stained control FCS files.

control.def.file

CSV file defining the single-color control file names, fluorophores they represent, marker names, peak channels, and gating requirements.

asp

The AutoSpectral parameter list.

min.event.warning

The number of events in the entire FCS file that will trigger a warning if not met.

min.event.error

The number of events in the entire FCS file that will trigger an error if not met.

legacy

Logical. If FALSE, gating-related columns will not be created and the control file will be suitable only for the new automated spectral extraction pipeline using get.spectra.automated(). To use the version 1 "legacy" pipeline for the extraction of fluorophore spectra, using gating and define.flow.control(), set legacy=TRUE.

allow.duplicate.controls

Logical, default FALSE. If FALSE, multiple controls for the same fluorophore are flagged as an error. Set to TRUE to permit them for diagnostic/QC use (e.g. comparing two preparations of the same conjugate); each will be assigned a unique sample identifier. The resulting reference library still must be reduced to one row per fluorophore before it can be used for unmixing – see check.spectra.duplicates().

Value

A dataframe of errors and warnings intended to help the user fix problems with the control.def.file.