Draw one of the standard surrogate-variable plots used by svaEnmix().

plotSvaEnmix(
  analysisData,
  plot = c("sentrix_id", "sentrix_position", "matrix"),
  display = FALSE,
  file = NULL,
  width = 2000L,
  height = 1000L,
  res = 150L,
  verbose = FALSE,
  logs = FALSE,
  log_dir = NULL,
  log_file = "log_plotSvaEnmix.txt"
)

Arguments

analysisData

Object returned by analyzeSvaEnmix().

plot

Character. Plot type: "sentrix_id", "sentrix_position", or "matrix".

display

Logical. If TRUE, draw the plot on the active graphics device.

file

Character or NULL. TIFF file path used for saved output.

width

Integer. Plot width in pixels when file is supplied.

height

Integer. Plot height in pixels when file is supplied.

res

Integer. TIFF resolution in DPI when file is supplied.

verbose

Logical. If TRUE, emit progress messages with message().

logs

Logical. If TRUE, write the same messages to a log file.

log_dir

Character or NULL. Directory used for the log file when logs = TRUE.

log_file

Character. File name used when logs = TRUE.

Value

Invisibly returns file when a TIFF is written, otherwise NULL.

Examples

ex <- dnaEPICO:::exampleSvaAnalysisStateDnaEpico()
plotSvaEnmix(
  analysisData = ex$analysisData,
  plot = "sentrix_id",
  display = FALSE,
  verbose = FALSE,
  logs = FALSE
)