Skip to contents

Takes the dataframe generated from CytekQCFilePrep and returns all the QC plots

Usage

QC_Plots(
  x,
  FailedFlag,
  MeasurementType = NULL,
  Metadata = NULL,
  plotType = "individual",
  returntype,
  path,
  filename,
  thecolumns = 1,
  therows = 3,
  width = 7,
  height = 9,
  strict = FALSE,
  YAxisLabel = NULL,
  RepairVisits = NULL
)

Arguments

x

The data frame object of Aurora QC data generated by CytekQCFilePrep

FailedFlag

Whether to show red flags when a detectors "Out-of-Range" is TRUE

MeasurementType

A list containing character values, will select any present from the column names for plotting

Metadata

An optional character column to use as ggplot factor.

plotType

Whether to return "individual" plots or "comparison" plots (provide Metadata name!)

returntype

Whether to return to pdf, patchwork or plots.

path

Location path to return the pdf

filename

File name to save as.

thecolumns

The number of columns per page

therows

The number of rows per page

width

Desired page width

height

Desired page height

strict

Default FALSE, when TRUE, parameters must be exact match for MeasurementType rather than simply containing those character strings.

YAxisLabel

Character string for the y-axis label.

RepairVisits

Passed data.frame of engineer visits for vertical lines, default NULL.

Value

The pdf and/the plots.

Examples

library(ggplot2)

File_Location <- system.file("extdata", package = "Luciernaga")
CSV_Pattern <- ".CSV$"
CSV_Files <- list.files(path=File_Location, pattern=CSV_Pattern,
                       full.names=TRUE)
TidyData <- QC_FilePrep(CSV_Files, TrackChange = FALSE)
#> Error in QC_FilePrep(CSV_Files, TrackChange = FALSE): could not find function "QC_FilePrep"

StorageLocation <- file.path("C:", "Users", "JohnDoe", "Desktop")

SinglePlot <- "UV7-Gain"

TheSinglePlot <- QC_Plots(x = TidyData, MeasurementType = SinglePlot,
                         FailedFlag = TRUE, returntype="patchwork",
                         path=StorageLocation, filename="CytekAurora5L_QC")
#> Error in h(simpleError(msg, call)): error in evaluating the argument 'x' in selecting a method for function 'colnames': object 'TidyData' not found