[BioC] Align two protein sequences using BLAST

Patrick Aboyoun paboyoun at fhcrc.org
Wed Jan 6 20:06:33 CET 2010


Alla,
The pairwiseAlignment in the Biostrings package can align (in a local, 
global, overlap, global-local, local-global fashion) two protein 
sequences and there are a number of predefined PAM and BLOSUM 
substitution matrices you can use when constructing the alignment. For 
more information see

library(Biostrings)
help(substitution.matrices)
help(pairwiseAlignment)

Here is an example:

 > aa1 <- AAString("HXBLVYMGCHFDCXVBEHIKQZ")
 > aa2 <- AAString("QRNYMYCFQCISGNEYKQN")
 > pairwiseAlignment(aa1, aa2, substitutionMatrix = "BLOSUM62", 
gapOpening = -3, gapExtension = -1)
Global PairwiseAlignedFixedSubject (1 of 1)
pattern: [1] HXBLVYMGCHFDCXV--BEHIKQZ
subject: [1] QRN--YMYC-FQC-ISGNEY-KQN
score: 38

 > sessionInfo()
R version 2.11.0 Under development (unstable) (2010-01-02 r50884)
i386-apple-darwin9.8.0

locale:
[1] en_US.UTF-8/en_US.UTF-8/C/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base    

other attached packages:
[1] Biostrings_2.15.11 IRanges_1.5.23   

loaded via a namespace (and not attached):
[1] Biobase_2.7.3 tcltk_2.11.0  tools_2.11.0


Cheers,
Patrick



Alla Bulashevska wrote:
> Dear Bioconductor users,
> I would like to align two protein sequences using BLAST
> (bl2seq). The question is whether this programm have been
> implemented in R.
> Thank you for your help,
> Alla.
>
> _______________________________________________
> 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
>



More information about the Bioconductor mailing list