qualPlot-methods: Plot a Base Quality Boxplot by Position

Description Usage Arguments Methods Author(s) See Also Examples

Description

basePlot plots quality statistics by position. Optionally, it adds a smoothed curve through the qualities, which is fit with data randomly drawn from the distribution of qualities at each position.

The grey lines indicate the range of the 10% and 90% quantiles, the orange lines indicate the range of the 25% and 75% quartiles, the blue point is the mean. Optionally, one can plot the median as well.

Usage

1
  qualPlot(x, smooth=TRUE, extreme.color="grey", quartile.color="orange", mean.color="blue", median.color=NULL)

Arguments

x

an S4 object of class FASTQSummary from readSeqFile or a list of FASTQSummary objects with names.

smooth

a logical value indicating whether to add a smooth curve.

extreme.color

a character value indicating the color to use for the extreme values (the 10% and 90% quantiles). If NULL, these line seqments will not be added.

quartile.color

a character value indicating the color to use for the quartiles. If NULL, these line seqments will not be added.

mean.color

a character value indicating the color to use for the mean. If NULL, these line seqments will not be added.

median.color

a character value indicating the color to use for the median. If NULL, these line seqments will not be added.

Methods

signature(x = "FASTQSummary")

qualPlot will plot the qualities for a single object of class FASTQSummary.

signature(x = "list")

qualPlot will plot the qualities for each of the FASTQSummary items in the list and display them in a series of panels.

Author(s)

Vince Buffalo <vsbuffalo@ucdavis.edu>

See Also

getQual

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
  ## Load a FASTQ file
  s.fastq <- readSeqFile(system.file('extdata', 'test.fastq', package='qrqc'))

  ## Plot qualities
  qualPlot(s.fastq)

  ## Combine with ggplot2 to produce custom graphics
  p <- qualPlot(s.fastq, smooth=FALSE)
  p <- p + geom_smooth(aes(x=position, y=quality),
    data=getMCQual(s.fastq), method="lm", color="green", se=FALSE)
  p <- p + theme_bw()
  p

  ## Plot multiple quality plots
  s.trimmed.fastq <- readSeqFile(system.file('extdata',
    'test-trimmed.fastq', package='qrqc'))
  qualPlot(list("not trimmed"=s.fastq, "trimmed"=s.trimmed.fastq))

vsbuffalo/qrqc documentation built on May 3, 2019, 7:07 p.m.