I use pairwise align to get the following:
> alignment <-pairwiseAlignment(pattern = canonical.protein, subject=protein.extracted)
> alignment
Global PairwiseAlignedFixedSubject (1 of 1)
pattern: [448] DDWEIPDGQITVGQRIGSGSFGTVYKGKWHGDVAVKMLNVTAPTPQQLQAFKNEVGV...FMVGRGYLSPDLSKVRSNCPKAMKRLMAE CLKKKRDERPLFPQILASIELLARSLPK
subject: [1] DDWEIPDGQITVGQRIGSGSFGTVYKGKWHGDVAVKMLNVTAPTPQQLQAFKNEVGV...FMVGRGYLSPDLSKVRSNCPKAMKRLMAECLKKKRDERPLFPQILASIELLARSLPK
score: -912.3752
I can then use:
toString(pattern(alignment))
toString(subject(alignment))
to get the full string sequence for both the pattern and the subject. However, how do I get the number 448 and 1 out of the object as an integer? I need to use these numbers but there doesn't seem to be a way to get at them.
I believe these are the
start
s of the alignments, soYour question would be clearer with a fully reproducible example, e.g.,
Then
Also, the Bioconductor mailing list is more appropriate for these questions; no subscription required.