readGALP | R Documentation |
Read bam file into GAlignmentPairs object
readGALP(
bamfile,
use_names = TRUE,
chromosome_to_keep = paste("chr", 1:22, sep = ""),
strand_mode = 1,
genome_label = "hg19",
outdir = FALSE,
galp_flag = Rsamtools::scanBamFlag(isPaired = TRUE, isDuplicate = FALSE,
isSecondaryAlignment = FALSE, isUnmappedQuery = FALSE, isSupplementaryAlignment =
FALSE),
galp_what = c("cigar", "mapq", "isize"),
galp_tag = c("NM", "MD"),
galp_mapqFilter = 30,
...
)
bamfile |
The bam file name. |
use_names |
|
chromosome_to_keep |
Should be a character vector containing the seqnames to be kept in the GRanges object or boolean FALSE. FALSE means not filtering. Default is paste0("chr", 1:22). |
strand_mode |
Usually the strand_mode = 1 means the First read is aligned to positive strand. Details please see GenomicAlignments docs. |
genome_label |
The Genome you used in the alignment. Should be "hg19" or "hg38" or "hg38-NCBI". Default is "hg19". Note: "hg19" will load BSgenome.Hsapiens.UCSC.hg19 package, which is Full genome sequences for Homo sapiens (Human) as provided by UCSC (hg19, based on GRCh37.p13) and stored in Biostrings objects; "hg38" will load BSgenome.Hsapiens.UCSC.hg38 package, which is Full genome sequences for Homo sapiens (Human) as provided by UCSC (hg38, based on GRCh38.p13) and stored in Biostrings objects. "hg38-NCBI" will load BSgenome.Hsapiens.NCBI.GRCh38 package, which is full genome sequences for Homo sapiens (Human) as provided by NCBI (GRCh38, 2013-12-17) and stored in Biostrings objects. |
outdir |
The path for saving rds file. Default is NA, i.e. not saving. |
galp_flag |
|
galp_what |
A character vector naming the fields to return Rsamtools::scanBamWhat() returns a vector of available fields. Fields are described on the Rsamtools::scanBam help page. |
galp_tag |
|
galp_mapqFilter |
|
... |
Further arguments passed to or from other methods. |
This function returns curated GRanges object.
Haichao Wang
## Not run:
object <- readGALP(bamfile = "/path/to/bamfile.bam",
outdir = "./",
chromosome_to_keep = c("chr1", "chr2", "chr3"))
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.