Class DisplayAFP


  • public class DisplayAFP
    extends Object
    A utility class for visualistion of structure alignments
    Author:
    Andreas Prlic
    • Constructor Summary

      Constructors 
      Constructor Description
      DisplayAFP()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static org.biojava.nbio.structure.Structure createArtificalStructure​(org.biojava.nbio.structure.align.model.AFPChain afpChain, org.biojava.nbio.structure.Atom[] ca1, org.biojava.nbio.structure.Atom[] ca2)
      Create a "fake" Structure objects that contains the two sets of atoms aligned on top of each other.
      static StructureAlignmentJmol display​(org.biojava.nbio.structure.align.model.AFPChain afpChain, org.biojava.nbio.structure.Group[] twistedGroups, org.biojava.nbio.structure.Atom[] ca1, org.biojava.nbio.structure.Atom[] ca2, List<org.biojava.nbio.structure.Group> hetatms1, List<org.biojava.nbio.structure.Group> hetatms2)
      Note: ca2, hetatoms2 and nucleotides2 should not be rotated.
      static org.biojava.nbio.structure.Atom[] getAtomArray​(org.biojava.nbio.structure.Atom[] ca, List<org.biojava.nbio.structure.Group> hetatms)
      Returns the first atom for each group
      static org.biojava.nbio.structure.Atom getAtomForAligPos​(org.biojava.nbio.structure.align.model.AFPChain afpChain, int chainNr, int aligPos, org.biojava.nbio.structure.Atom[] ca, boolean getPrevious)
      Return the atom at alignment position aligPos.
      static List<Integer> getEQRAlignmentPos​(org.biojava.nbio.structure.align.model.AFPChain afpChain)  
      static List<String> getPDBresnum​(int aligPos, org.biojava.nbio.structure.align.model.AFPChain afpChain, org.biojava.nbio.structure.Atom[] ca)
      Return a list of pdb Strings corresponding to the aligned positions of the molecule.
      static void showAlignmentImage​(org.biojava.nbio.structure.align.model.AFPChain afpChain, String result)  
      static void showAlignmentPanel​(org.biojava.nbio.structure.align.model.AFPChain afpChain, org.biojava.nbio.structure.Atom[] ca1, org.biojava.nbio.structure.Atom[] ca2, AbstractAlignmentJmol jmol)  
    • Constructor Detail

      • DisplayAFP

        public DisplayAFP()
    • Method Detail

      • getEQRAlignmentPos

        public static final List<Integer> getEQRAlignmentPos​(org.biojava.nbio.structure.align.model.AFPChain afpChain)
      • getPDBresnum

        public static final List<String> getPDBresnum​(int aligPos,
                                                      org.biojava.nbio.structure.align.model.AFPChain afpChain,
                                                      org.biojava.nbio.structure.Atom[] ca)
        Return a list of pdb Strings corresponding to the aligned positions of the molecule. Only supports a pairwise alignment with the AFPChain DS.
        Parameters:
        aligPos -
        afpChain -
        ca -
      • getAtomForAligPos

        public static final org.biojava.nbio.structure.Atom getAtomForAligPos​(org.biojava.nbio.structure.align.model.AFPChain afpChain,
                                                                              int chainNr,
                                                                              int aligPos,
                                                                              org.biojava.nbio.structure.Atom[] ca,
                                                                              boolean getPrevious)
                                                                       throws org.biojava.nbio.structure.StructureException
        Return the atom at alignment position aligPos. at the present only works with block 0
        Parameters:
        chainNr - the number of the aligned pair. 0... first chain, 1... second chain.
        afpChain - an afpChain object
        aligPos - position on the alignment
        getPrevious - gives the previous position if false, gives the next posible atom
        Returns:
        a CA atom that is at a particular position of the alignment
        Throws:
        org.biojava.nbio.structure.StructureException
      • getAtomArray

        public static final org.biojava.nbio.structure.Atom[] getAtomArray​(org.biojava.nbio.structure.Atom[] ca,
                                                                           List<org.biojava.nbio.structure.Group> hetatms)
                                                                    throws org.biojava.nbio.structure.StructureException
        Returns the first atom for each group
        Parameters:
        ca -
        hetatms -
        Returns:
        Throws:
        org.biojava.nbio.structure.StructureException
      • display

        public static final StructureAlignmentJmol display​(org.biojava.nbio.structure.align.model.AFPChain afpChain,
                                                           org.biojava.nbio.structure.Group[] twistedGroups,
                                                           org.biojava.nbio.structure.Atom[] ca1,
                                                           org.biojava.nbio.structure.Atom[] ca2,
                                                           List<org.biojava.nbio.structure.Group> hetatms1,
                                                           List<org.biojava.nbio.structure.Group> hetatms2)
                                                    throws org.biojava.nbio.structure.StructureException
        Note: ca2, hetatoms2 and nucleotides2 should not be rotated. This will be done here...
        Throws:
        org.biojava.nbio.structure.StructureException
      • showAlignmentPanel

        public static void showAlignmentPanel​(org.biojava.nbio.structure.align.model.AFPChain afpChain,
                                              org.biojava.nbio.structure.Atom[] ca1,
                                              org.biojava.nbio.structure.Atom[] ca2,
                                              AbstractAlignmentJmol jmol)
                                       throws org.biojava.nbio.structure.StructureException
        Throws:
        org.biojava.nbio.structure.StructureException
      • showAlignmentImage

        public static void showAlignmentImage​(org.biojava.nbio.structure.align.model.AFPChain afpChain,
                                              String result)
      • createArtificalStructure

        public static org.biojava.nbio.structure.Structure createArtificalStructure​(org.biojava.nbio.structure.align.model.AFPChain afpChain,
                                                                                    org.biojava.nbio.structure.Atom[] ca1,
                                                                                    org.biojava.nbio.structure.Atom[] ca2)
                                                                             throws org.biojava.nbio.structure.StructureException
        Create a "fake" Structure objects that contains the two sets of atoms aligned on top of each other.
        Parameters:
        afpChain - the container of the alignment
        ca1 - atoms for protein 1
        ca2 - atoms for protein 2
        Returns:
        a protein structure with 2 models.
        Throws:
        org.biojava.nbio.structure.StructureException