pairwiseAlignment and issue mapping
1
0
Entering edit mode
@james-bullard-1231
Last seen 9.7 years ago
Hi All, this should be an easy question and answer, it is mostly about the best way to do this with the Bioconductor S4 classes. I have a pairwise alignment: A and I want a function which maps from a position in the original sequence (either subject: s, or pattern: p) to the position in the aignment. Essentially, I want a function that looks like: subject alignment 1 1 2 2 3 4 4 5 alignmentPosition(i, which = c("subject", "pattern")), i in 1:length(s) => j in 1:length(alignment) If I had just characters, it would be easy, but since I have objects of type: PairwiseAlignedFixedSubject, I am slightly overwhelmed by the class hierarchy, and the best way to do this. thanks, jim
• 742 views
ADD COMMENT
0
Entering edit mode
Patrick Aboyoun ★ 1.6k
@patrick-aboyoun-6734
Last seen 9.7 years ago
United States
Jim, Table 3 (Functions for AlignedXString and QualityAlignedXString objects) in Biostrings' Pairwise Alignment vignette http://bioconductor.org/packages/2.5/bioc/vignettes/Biostrings/inst/do c/Alignments.pdf lists some helper functions that may be of use to you. A PairwiseAlignedFixedSubject object has two slots, one for the pattern and one for the subject, to house AlignedXStringSet objects These objects should contain the information you are looking for. In particular, I think myalign <- pairwiseAlignment(...) start(subject(myalign)) should do the trick. Patrick James Bullard wrote: > Hi All, > > this should be an easy question and answer, it is mostly about the > best way to do this with the Bioconductor S4 classes. I have a > pairwise alignment: A and I want a function which maps from a position > in the original sequence (either subject: s, or pattern: p) to the > position in the aignment. Essentially, I want a function that looks like: > > subject alignment > 1 1 > 2 2 > 3 4 > 4 5 > > alignmentPosition(i, which = c("subject", "pattern")), i in > 1:length(s) => j in 1:length(alignment) > > If I had just characters, it would be easy, but since I have objects > of type: PairwiseAlignedFixedSubject, I am slightly overwhelmed by the > class hierarchy, and the best way to do this. > > thanks, jim > > _______________________________________________ > Bioconductor mailing list > Bioconductor at stat.math.ethz.ch > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: > http://news.gmane.org/gmane.science.biology.informatics.conductor
ADD COMMENT

Login before adding your answer.

Traffic: 438 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6