ezScanBam: Scans a bam file

View source: R/bamio.R

ezScanBamR Documentation

Scans a bam file

Description

Scans a bam file with the option to select only a part of the output.

Usage

ezScanBam(
  bamFile,
  seqname = NULL,
  start = NULL,
  end = NULL,
  strand = "*",
  tag = character(0),
  what = scanBamWhat(),
  isFirstMateRead = NA,
  isSecondMateRead = NA,
  isUnmappedQuery = FALSE,
  isProperPair = NA,
  isSecondaryAlignment = NA,
  isDuplicate = NA,
  countOnly = FALSE
)

Arguments

bamFile

a character representing the bam file path.

seqname

an optional character vector to keep only the specified sequence names in the returned reads.

start

an optional integer vector to limit the start position of the range of returned reads.

end

an optional integer vector to limit the start position of the range of returned reads.

strand

a character specifying which strand to use (+, - or *).

tag

passed further to ScanBamParam().

what

passed further to ScanBamParam().

isFirstMateRead

passed further to scanBamFlag().

isSecondMateRead

passed further to scanBamFlag().

isUnmappedQuery

passed further to scanBamFlag().

isProperPair

passed further to scanBamFlag().

countOnly

a logical specifying whether only counts should be returned or the whole scan of the bam file.

Value

Returns a list representing a scanned bam file.

Author(s)

Rehrauer, Hubert

Schmid, Peter

See Also

scanBam

ScanBamParam

Examples

bamFile <- system.file("extdata", "ex1.bam", package="Rsamtools", mustWork=TRUE)
bam = ezScanBam(bamFile)

uzh/ezRun documentation built on May 9, 2024, 6:16 p.m.