Sam: Create a sam (sequence alignment/map) object.

Description Usage Arguments Details Value Examples

View source: R/Sam.R

Description

An object of class Sam represents a ‘*.sam’ file. This is supposed to be an opaque object for use by other functions. The size of a sam object is limited to only what can be read into memory and manipulated, which is probably at best about 1/3 of the total memory on the system (due to R functions being "copy by value".) No support is provided for ‘*.bam’ files.

Usage

1
Sam(file, splitTags = TRUE)

Arguments

file

A *.sam file name.

splitTags

Parse optional sam file read tags into columns. True by default, but increases processing time a factor of 4 or so. If false will have only one "tags" column with a single tab-delimited string.

Details

A sam object is composed of three parts, a SamHeader, SamReads, and SamSource data. These parts can be extracted as objects of the same name by constructor functions of the same name applied to the Sam object. Any function that works when applied to a component object will work on the Sam object too.

Value

An object of class Sam.

Examples

1
2
3
4
5
6
7
8
## Not run: 
samObj <- Sam( 'myFile.sam' )

myHeader <- samHeader(samObj)
myReads <- samReads(samObj)
mySource <- samSource(samObj)

## End(Not run)

jefferys/SamSeq documentation built on Oct. 25, 2019, 8:11 a.m.