[Bioperl-l] hmm alignment

Jason Stajich jason at cgt.duhs.duke.edu
Fri May 14 07:35:38 EDT 2004


On Fri, 14 May 2004 stephan.rosecker at ish.de wrote:

> hi list,
>
> i'm looking for a way to get the alignment from an hmmpfam output.
> I like to show the aligmnet e.g on the commandline in the same
> format as hmmpfam, is there an easyer way to do this, or only possible
> in manual operation with:
> $hsp->query_string;
> $hsp->hit_string;
> ... some string operationes
> (HMMERHSP get_aln() is deprecated ...)

If you want to see the aln just like HMMER get_aln wouldn't work either as
there is no HMMER-style AlignIO and so there won't be any way to view the
middle homology line from the alignment.  Maybe we should develop a simple
pairwise alignment writer just for HSPs at some point...

N.B. I also also don't parse the RF lines currently either so the
reconstituted alignment won't be identical.

But I think to do what you want just requires some manipulation
with the hit_strand,query_string, homology_string -- see
SearchIO::Writer::TextResultWrite of an example of how we reconstitute
BLAST alignment from HSPs.  I know it is a little dense but around about
line 394 we start making an HSP for an alignment.

-jason

>
>
> This is what i want...
>
>
>                    *->GIeEkIkaIEeEiarTqKNKATEyHLGlLKaKLAkLReQLlEpskgg
>                        I+EkI aIE E+arTqKNKAT  HLGlLKa  AkLR +L   s +g
>   128U_DROME     4    -ILEKISAIESEMARTQKNKATSAHLGLLKANVAKLRRELI--SPKG 47
>
>                    gGGG...kGFeVeKSGdarvaLIGfPSVGKStLLakLTntkSEvAdYaFT
>                    gGGG+++ GFeV+K Gdarv ++GfPSVGKStLL+ L +  SEvA+Y+FT
>   128U_DROME    48 GGGGtgeAGFEVAKTGDARVGFVGFPSVGKSTLLSNLAGVYSEVAAYEFT 97
>
>                    TLTcvPGvLeYqgakIQllDlPGIIeGAssGKGRGrqVlAvarsADLvLm
>                    TLT vPG ++Y+gakIQllDlPGIIeGA  GKGRGrqV+Avar+  L+ m
>   128U_DROME    98 TLTTVPGCIKYKGAKIQLLDLPGIIEGAKDGKGRGRQVIAVARTCNLIFM 147
>
>                    vLDatkleehrdvLekELEnVGIRLnkrkGPniyfKkKetGGvsvngTgp
>                    vLD  k+ +h  +Le ELE  GIRLnk++ Pniy+K K  GG++ n+ +p
>   128U_DROME   148 VLDCLKPLGHKKLLEHELEGFGIRLNKKP-PNIYYKRKDKGGINLNSMVP 196
>
>                    PLThidEdtvrrILheYRIhNAeVliReDqvTlDdFIDVVnegNRvYipc
>                       ++d d+v++IL+eY+IhNA++  R D +T Dd IDV+ egNR Yipc
>   128U_DROME   197 -QSELDTDLVKTILSEYKIHNADITLRYD-ATSDDLIDVI-EGNRIYIPC 243
>
>                    LyVyNKIDlvgieevdrlarkrlEiGpntIVvScnmglnLdelaerlwek
>                    +y +NKID+++iee+d + +      p  + +S+    n d+l+e +we
>   128U_DROME   244 IYLLNKIDQISIEELDVIYKI-----PHCVPISAHHHWNFDDLLELMWEY 288
>
>                    LglvRVYtKkqGkePDFDPLvepLilRrGsT.VeDvChhiHrDLvrrFKY
>                    L l R+YtK++G+ PD+     p +l +  T++eD+C+++Hr  +++FKY
>   128U_DROME   289 LRLQRIYTKPKGQLPDYN---SPVVLHNERTsIEDFCNKLHRSIAKEFKY 335
>
>                    AlVWGkSaKhppQrVGleHvleDeDvvqivvK<-*
>                    AlVWG+S+Kh pQ+VG+eHvl DeDvvqiv+K
>   128U_DROME   336 ALVWGSSVKHQPQKVGIEHVLNDEDVVQIVKK    367
> _______________________________________________
> Bioperl-l mailing list
> Bioperl-l at portal.open-bio.org
> http://portal.open-bio.org/mailman/listinfo/bioperl-l
>

--
Jason Stajich
Duke University
jason at cgt.mc.duke.edu


More information about the Bioperl-l mailing list