loadMummer | R Documentation |
Load alignment coordinates from MUMmer.
loadMummer(
file.coords,
algo = "nucmer",
asGRanges = TRUE,
keep.nlong.qry = NULL,
ref.lim = NULL,
verbose = 1
)
file.coords |
path to the file with alignment coordinates obtained via |
algo |
nucmer or promer (the latter isn't available yet) |
asGRanges |
if TRUE, returns a |
keep.nlong.qry |
keep the N queries having the longest cumulated alignments on the reference (keep all of them by default) |
ref.lim |
limits on reference coordinates outside which alignments are discarded (keep all of them by default) |
verbose |
verbosity level (0/1) |
GRanges or data.frame
Timothee Flutre
mummer2granges
## Not run: ## MUMmer should be run beforehand, for instance:
## nucmer --maxmatch -p out-nucmer chroms.fa seqs.fa
## delta-filter -l 1000 -q out-nucmer.delta > out-nucmer_filter.delta
## show-coords -c -l -L 1000 -r -T out-nucmer_filter.delta | gzip > out-nucmer_filter_coords.txt.gz
coords <- loadMummer("out-nucmer_filter_coords.txt.gz")
library(GenomicRanges)
loc <- GRanges(seqnames=Rle("chr1"),
ranges=IRanges(start=5, end=17))
idx <- subjectHits(findOverlaps(query=loc, subject=coords.gr))
plotAligns(coords=as.data.frame(ranges(coords.gr[idx,])))
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.