Class SequenceFunctionRefiner
- java.lang.Object
-
- org.biojava.nbio.structure.symmetry.internal.SequenceFunctionRefiner
-
- All Implemented Interfaces:
SymmetryRefiner
public class SequenceFunctionRefiner extends Object implements SymmetryRefiner
Creates a refined alignment with the CE-Symm alternative self-alignment. Needs the order of symmetry and assumes that the last repeat aligns with the first, being thus a CLOSE symmetry.- Since:
- 4.2.0
- Author:
- Spencer Bliven, Aleix Lafita
-
-
Constructor Summary
Constructors Constructor Description SequenceFunctionRefiner()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description MultipleAlignment
refine(AFPChain selfAlignment, Atom[] atoms, int order)
Returns a refined symmetry alignment, where the repeat residues are aligned consistently in a MultipleAlignment.static Map<Integer,Integer>
refineSymmetry(Map<Integer,Integer> alignment, int k)
Refines a CE-Symm alignment so that it is perfectly symmetric.static AFPChain
refineSymmetry(AFPChain afpChain, Atom[] ca1, Atom[] ca2, int k)
Refines a CE-Symm alignment so that it is perfectly symmetric.
-
-
-
Constructor Detail
-
SequenceFunctionRefiner
public SequenceFunctionRefiner()
-
-
Method Detail
-
refine
public MultipleAlignment refine(AFPChain selfAlignment, Atom[] atoms, int order) throws RefinerFailedException, StructureException
Description copied from interface:SymmetryRefiner
Returns a refined symmetry alignment, where the repeat residues are aligned consistently in a MultipleAlignment.- Specified by:
refine
in interfaceSymmetryRefiner
- Parameters:
selfAlignment
- optimal self-alignment calculated by CeSymmatoms
- coordinates of the structureorder
- order of symmetry to use- Returns:
- MultipleAlignment refined symmetry alignment
- Throws:
RefinerFailedException
StructureException
-
refineSymmetry
public static AFPChain refineSymmetry(AFPChain afpChain, Atom[] ca1, Atom[] ca2, int k) throws StructureException, RefinerFailedException
Refines a CE-Symm alignment so that it is perfectly symmetric. The resulting alignment will have a one-to-one correspondance between aligned residues of each symmetric part.- Parameters:
afpChain
- Input alignment from CE-Symmk
- Symmetry order. This can be guessed byCeSymm#getSymmetryOrder(AFPChain)
- Returns:
- The refined alignment
- Throws:
StructureException
RefinerFailedException
-
refineSymmetry
public static Map<Integer,Integer> refineSymmetry(Map<Integer,Integer> alignment, int k) throws StructureException
Refines a CE-Symm alignment so that it is perfectly symmetric. The resulting alignment will have a one-to-one correspondance between aligned residues of each symmetric part.- Parameters:
alignment
- The input alignment, as a map. This will be modified.k
- Symmetry order. This can be guessed byCeSymm#getSymmetryOrder(AFPChain)
- Returns:
- A modified map with the refined alignment
- Throws:
StructureException
-
-