Description Usage Arguments Value Examples
Retrieve reads (BAM files) or variants (VCF files)
1 2 3 4 5 | htsget_reads(granges, sample_id, url, fields = NULL, destination)
BAMfields()
htsget_variants(granges, sample_id, url, destination)
|
granges |
|
sample_id |
|
url |
|
fields |
|
destination |
|
htsget_reads()
return the path to a BAM file containing
the requested information.
BAMfields()
returns a data.frame describing available
fields.
htsget_variants()
returns a character(1)
path to a VCF file
containing requested information.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | gr <- GenomicRanges::GRanges("chr12:111766922-111817529")
sample_id <- "platinum/NA12878"
url <- "https://htsnexus.rnd.dnanex.us/v1"
fl <- tempfile(fileext=".bam")
bam <- htsget_reads(gr, sample_id, url, destination = fl)
Rsamtools::countBam(bam)
BAMfields()
fl <- tempfile(fileext=".bam")
fields <- c("RNAME", "POS", "CIGAR")
bam <- htsget_reads(gr, sample_id, url, fields, destination = fl)
names(Rsamtools::scanBam(bam)[[1]])
gr <- GenomicRanges::GRanges("12:112204691-112247789")
sample_id <- "1000genomes/20130502_autosomes"
url <- "https://htsnexus.rnd.dnanex.us/v1"
fl <- tempfile(fileext=".vcf")
vcf <- htsget_variants(gr, sample_id, url, destination = fl)
VariantAnnotation::readVcf(vcf)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.