RFLPplot: Function to plot RFLP data.

Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/RFLPplot.R

Description

Given RFLP data is plotted where the samples are sorted according to the corresponding dendrogram.

Usage

1
2
3
4
RFLPplot(x, nrBands, nrMissing, distfun = dist, 
         hclust.method = "complete", mar.bottom = 5, 
         cex.axis = 0.5, colBands, xlab = "", 
         ylab = "molecular weight", ylim, ...)

Arguments

x

data.frame with RFLP data; see RFLPdata.

nrBands

if not missing, then only samples with the specified number of bands are considered.

nrMissing

if not missing, then it is assumed that some bands may be missing. That is, all samples with number of bands in nrBands, nrBands+1, ..., nrBands+nrMissing are considered.

distfun

function computing the distance with default dist; see dist.

hclust.method

method used for hierarchical clustering; see hclust.

mar.bottom

bottom margin of the plot; see par.

cex.axis

size of the x-axis annotation.

colBands

color for the bands. Has to be of length 1 or number of samples. If missing, "Set1" of RColorBrewer is used; see ColorBrewer.

xlab

passed to function plot.

ylab

passed to function plot.

ylim

passed to function plot. If missing an appropriate range of y-values is computed.

...

additional arguments passed to function plot except xlim which is defined inside of RFLPplot.

Details

RFLP data is plotted. The samples are sorted according to the corresponding dendrogram which is computed via function hclust.

The option to specify nrMissing may be useful, if gel image quality is low, and the detection of bands is doubtful.

Value

invisible

Author(s)

Fabienne Flessa Fabienne.Flessa@uni-bayreuth.de,
Alexandra Kehl Alexandra.Kehl@uni-tuebingen.de,
Matthias Kohl Matthias.Kohl@stamats.de

References

Flessa, F., Kehl, A., Kohl, M. Analysing diversity and community structures using PCR-RFLP: a new software application. Molecular Ecology Resources 2013 Jul; 13(4):726-33.

See Also

RFLPdata, dist

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
data(RFLPdata)
par(mfrow = c(1,2))
plot(hclust(RFLPdist(RFLPdata, nrBands = 3)), cex = 0.7)
RFLPplot(RFLPdata, nrBands = 3, mar.bottom = 6, cex.axis = 0.8)

par(mfrow = c(1,2))
plot(hclust(RFLPdist2(RFLPdata, nrBands = 9, nrMissing = 1)), cex = 0.7)
RFLPplot(RFLPdata, nrBands = 9, nrMissing = 1, mar.bottom = 6, cex.axis = 0.8)


distfun <- function(x) dist(x, method = "maximum")
par(mfrow = c(1,2))
plot(hclust(RFLPdist(RFLPdata, nrBands = 3, distfun = distfun), 
            method = "average"), cex = 0.7, cex.lab = 0.7)
RFLPplot(RFLPdata, nrBands = 3, distfun = distfun, hclust.method = "average", 
         mar.bottom = 6, cex.axis = 0.8)

Example output

Loading required package: RColorBrewer

RFLPtools documentation built on May 4, 2021, 1:06 a.m.