Learn R Programming

TRAMPR (version 1.0-5)

TRAMPsamples: TRAMPsamples Objects

Description

These functions create and interact with TRAMPsamples objects (collections of TRFLP patterns). Samples contrast with knowns (see TRAMPknowns) in that samples contain primarily unidentified profiles. In contrast with knowns, samples may have many peaks per enzyme/primer combination.

Usage

TRAMPsamples(data, info=NULL, warn.factors=TRUE, ...)

## S3 method for class 'TRAMPsamples':
labels(object, ...)
## S3 method for class 'TRAMPsamples':
summary(object, include.info=FALSE, ...)

Arguments

data
data.frame containing peak information.
info
(Optional) data.frame, describing individual samples (see Details for definitions of both data.frames). If this is omitted, a basic data.frame will be generated.
warn.factors
Logical: Should a warning be given if any columns in info or data are converted into factors?
object
A TRAMPsamples object.
include.info
Logical: Should the output be augmented with the contents of the info component of the TRAMPsamples object?
...
TRAMPsamples: Additional objects to incorportate into a TRAMPsamples object. Other methods: Further arguments passed to or from other methods.

Value

  • TRAMPsamplesA new TRAMPsamples object, as described above.
  • labels.TRAMPsamplesA sorted vector of the unique samples present in x (from info$sample.pk).
  • summary.TRAMPsamplesA data.frame, with the number of peaks per enzyme/primer combination, with each sample (indicated by sample.pk) as rows and each combination (in the format _) as columns.

Details

The object has at least two components, which relate to each other (in the sense of a relational database). info holds information about the individual samples, and data holds information about individual peaks (many of which belong to a single sample). Column definitions:
  • info:[object Object],[object Object]
  • data:[object Object],[object Object],[object Object],[object Object],[object Object]
Additional columns are allowed (and ignored) in both data.frames, and will be retained. This allows notes on data quality and treatments to be easily included. Additional objects are allowed as part of the TRAMPsamples object; any extra objects passed (via ...) will be included in the final TRAMPsamples object. If info is omitted, then a basic data.frame will be generated, containing just the unique values of sample.fk, and NA for species.

See Also

plot.TRAMPsamples and summary.TRAMPsamples, for plotting and summarising TRAMPsamples objects. TRAMPknowns, which constructs an analagous object to hold knowns data. TRAMP, for analysing TRAMPsamples objects. load.abi, which creates a TRAMPsamples object from Gene Mapper (Applied Biosystems) output.