CSP.heights.plot: likeLTD::CSP.heights.plot

Description Usage Arguments Details Value See Also Examples

View source: R/reports-peaks.R

Description

Plot one replicate from a peak heights CSP.

Usage

1
2
3
4
5
CSP.heights.plot(csp, refs, dbFile = NULL, kit = NULL, 
			outputFile = NULL, toPlot = NULL, 
			detectThresh = NULL, uncThresh = 0.05, 
			stutterThresh = 0.15, doStutter = FALSE,
			replicate = 1,...)

Arguments

csp

CSP as returned from read.peaks.profile.

refs

Reference profiles as returned by read.known.profiles.

dbFile

Path to allele database file. If NULL, kit is used instead.

kit

Choice of an allele database that is included wiht likeLTD. If both dbFile and kit are NULL, the DNA17 database is used.

outputFile

Path to output file. If NULL, the plot is output to a plot window instead.

toPlot

An integer vector specifying which loci to plot. If NULL, all loci are plotted.

detectThresh

Detection threshold used for electrophoresis analysis. If NULL, this is not plotted.

uncThresh

Threshold for suggesting that a peak is uncertain.

stutterThresh

Threshold for suggesting a peak is allelic.

doStutter

Logical. Specifies whether to suggest peaks as non-allelic/uncertain/allelic.

replicate

Which replicate to plot.

...

Extra parameters to pass to plot.

Details

If refFile is specified, the plotted peaks are coloured according to which reference individuals possess that allele. If detectThresh is specified, a horizontal line is plotted indicating the threshold. If doStutter=TRUE, the labels for each peak are coloured by a crude estimation of which peaks are allelic, uncertain, or non-allelic.

Value

Pdf file or plot window.

See Also

allele.report.peaks

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
## Not run: 
# datapath to example files
datapath = file.path(system.file("extdata", package="likeLTD"),"laboratory")

# File paths and case name for allele report
admin = pack.admin.input.peaks(
            peaksFile = file.path(datapath, 'laboratory-CSP.csv'),
            refFile = file.path(datapath, 'laboratory-reference.csv'),
            caseName = "Laboratory",
            detectionThresh = 20
             )

# plot CSP heights
CSP.heights.plot(csp=read.peaks.profile(admin$peaksFile),
		ref=read.known.profiles(admin$refFile))

# to plot just the first four loci
CSP.heights.plot(csp=read.peaks.profile(admin$peaksFile),
		ref=read.known.profiles(admin$refFile),
		toplot=1:4)

# to estimate which peaks are non-allelic
CSP.heights.plot(csp=read.peaks.profile(admin$peaksFile),
		ref=read.known.profiles(admin$refFile),
		doStutter=TRUE)

# to display detection threshold
CSP.heights.plot(csp=read.peaks.profile(admin$peaksFile),
		ref=read.known.profiles(admin$refFile),
		detectThresh=20)

## End(Not run)

likeLTD documentation built on May 1, 2019, 7:58 p.m.