Skip to content

Commit 77379f0

Browse files
committed
Change all references to Subunits to Repeats for consistency in CeSymm
1 parent 54578fc commit 77379f0

File tree

12 files changed

+154
-154
lines changed

12 files changed

+154
-154
lines changed

biojava-structure-gui/src/main/java/org/biojava/nbio/structure/symmetry/gui/SymmetryDisplay.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -56,17 +56,17 @@
5656
public class SymmetryDisplay {
5757

5858
/**
59-
* Displays a multiple alignment of the symmetry subunits.
59+
* Displays a multiple alignment of the symmetry repeats.
6060
*
6161
* * @param symm CeSymmResult
6262
*
6363
* @throws StructureException
6464
*/
65-
public static MultipleAlignmentJmol displaySubunits(CeSymmResult symm)
65+
public static MultipleAlignmentJmol displayRepeats(CeSymmResult symm)
6666
throws StructureException {
6767

68-
MultipleAlignment subunits = SymmetryTools.toSubunitAlignment(symm);
69-
return MultipleAlignmentJmolDisplay.display(subunits);
68+
MultipleAlignment repeats = SymmetryTools.toRepeatsAlignment(symm);
69+
return MultipleAlignmentJmolDisplay.display(repeats);
7070
}
7171

7272
/**
@@ -90,7 +90,7 @@ public static MultipleAlignmentJmol displayFull(CeSymmResult symm)
9090

9191
/**
9292
* Displays a single structure in a cartoon representation with each
93-
* symmetric subunit colored differently.
93+
* symmetric repeat colored differently.
9494
*
9595
* @param msa
9696
* the symmetry multiple alignment obtained from CeSymm
@@ -138,9 +138,9 @@ private static void addSymmetryMenu(MultipleAlignmentJmol jmol,
138138

139139
SymmetryListener li = new SymmetryListener(jmol, symmResult);
140140

141-
JMenuItem subunits = new JMenuItem("Subunit Superposition");
142-
subunits.addActionListener(li);
143-
symm.add(subunits);
141+
JMenuItem repeats = new JMenuItem("Repeats Superposition");
142+
repeats.addActionListener(li);
143+
symm.add(repeats);
144144

145145
JMenuItem multiple = new JMenuItem("Multiple Structure Alignment");
146146
multiple.addActionListener(li);

biojava-structure-gui/src/main/java/org/biojava/nbio/structure/symmetry/gui/SymmetryListener.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ public void actionPerformed(ActionEvent ae) {
6262
logger.error("Currently not displaying a symmetry!");
6363

6464
try {
65-
if (cmd.equals("Subunit Superposition")) {
66-
MultipleAlignmentJmol j = SymmetryDisplay.displaySubunits(symm);
65+
if (cmd.equals("Repeats Superposition")) {
66+
MultipleAlignmentJmol j = SymmetryDisplay.displayRepeats(symm);
6767
String s = SymmetryDisplay.printSymmetryAxes(symm, true);
6868
j.evalString(s);
6969

biojava-structure/src/main/java/org/biojava/nbio/structure/symmetry/internal/CESymmParameters.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public static enum RefineMethod {
6767
* includes the circular and dihedral symmetries, and OPEN: includes the
6868
* helical and protein repeats symmetries.
6969
* <p>
70-
* All internal symmetry cases share one property: all the subunits have the
70+
* All internal symmetry cases share one property: all the repeats have the
7171
* same 3D transformation.
7272
* <p>
7373
* AUTO option automatically identifies the type. The criterion for
@@ -211,12 +211,12 @@ public List<String> getUserConfigHelp() {
211211
+ "threshold will be considered asymmetric.");
212212
// SSE threshold
213213
params.add("SSE threshold: The minimum number of secondary structure "
214-
+ "elements (strands or helices) in each symmetrical subunit. "
215-
+ "If the subunits do not have enough SSE, the structure will "
214+
+ "elements (strands or helices) in each symmetrical repeat. "
215+
+ "If the repeats do not have enough SSE, the structure will "
216216
+ "be considered asymmetric. 0 means no restriction.");
217-
// min core subunit length
217+
// min core repeat length
218218
params.add("Minimum core length: the minimum number of non-gapped "
219-
+ "residues in every symmetric subunit.");
219+
+ "residues in every symmetric repeat.");
220220
// distance cutoff
221221
params.add("Distance Cutoff: the maximum allowed distance (in A) "
222222
+ "between two aligned residues.");

biojava-structure/src/main/java/org/biojava/nbio/structure/symmetry/internal/CeSymm.java

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -53,15 +53,15 @@
5353
* set of self-alignments (disabled, because none improvements were shown, but
5454
* can be turn on manually).
5555
* <p>
56-
* Multiple levels of symmetry can be analyzed by finding symmetries in subunits
56+
* Multiple levels of symmetry can be analyzed by finding symmetries in repeats
5757
* of previous results. This feature allows to find multiple symmetry axes.
5858
* <p>
5959
* The alignment is then refined to obtain a consistent alignment among all
6060
* residues of the structure and organized into different parts, called
61-
* symmetric subunits.
61+
* symmetric repeats.
6262
* <p>
6363
* After refinement of the initial alignment, an optimization step can be used
64-
* to improve the overall score of the subunit multiple alignment.
64+
* to improve the overall score of the repeat multiple alignment.
6565
*
6666
* @author Andreas Prlic
6767
* @author Spencer Bliven
@@ -77,7 +77,7 @@ public class CeSymm {
7777
* <ul>
7878
* <li>1.0 - initial implementation of CE-Symm.
7979
* <li>1.1 - enable multiple CE-Symm runs to calculate all self-alignments.
80-
* <li>2.0 - refine the alignment for consistency of subunit definition.
80+
* <li>2.0 - refine the alignment for consistency of repeat definition.
8181
* <li>2.1 - optimize the alignment to improve the score.
8282
* <li>2.2 - run multiple symmetry levels recursively to find PG and
8383
* hierarchical symmetries.
@@ -324,7 +324,7 @@ protected static CeSymmResult align(Atom[] atoms, CESymmParameters params)
324324
return result;
325325
}
326326

327-
// STEP4: determine the symmetry axis and its subunit dependencies
327+
// STEP4: determine the symmetry axis and its repeat dependencies
328328
SymmetryAxes axes = new SymmetryAxes();
329329
int order = result.getMultipleAlignment().size();
330330
Matrix4d axis = result.getMultipleAlignment().getBlockSet(0)
@@ -335,28 +335,28 @@ protected static CeSymmResult align(Atom[] atoms, CESymmParameters params)
335335
List<Integer> chain2 = new ArrayList<Integer>();
336336
superposition.add(chain1);
337337
superposition.add(chain2);
338-
List<Integer> subunitTrans = new ArrayList<Integer>();
338+
List<Integer> repeatTrans = new ArrayList<Integer>();
339339

340340
switch (result.getType()) {
341341
case CLOSED:
342342

343343
for (int bk = 0; bk < order; bk++) {
344344
chain1.add(bk);
345345
chain2.add((bk + 1) % order);
346-
subunitTrans.add(bk);
346+
repeatTrans.add(bk);
347347
}
348-
axes.addAxis(axis, superposition, subunitTrans, order);
348+
axes.addAxis(axis, superposition, repeatTrans, order);
349349
break;
350350

351351
default: // case OPEN:
352352

353-
subunitTrans.add(0);
353+
repeatTrans.add(0);
354354
for (int bk = 0; bk < order - 1; bk++) {
355355
chain1.add(bk);
356356
chain2.add(bk + 1);
357-
subunitTrans.add(bk + 1);
357+
repeatTrans.add(bk + 1);
358358
}
359-
axes.addAxis(axis, superposition, subunitTrans, order);
359+
axes.addAxis(axis, superposition, repeatTrans, order);
360360
break;
361361
}
362362
result.setAxes(axes);

biojava-structure/src/main/java/org/biojava/nbio/structure/symmetry/internal/CeSymmIterative.java

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060
* <li>Calculate the symmetric unit boundaries.
6161
* <li>Run CeSymm on one of the symmetric units to find further symmetries.
6262
* <li>Repeat the last two steps until no more significant results are found.
63-
* <li>Map back all residues in a multiple alignment of the subunits.
63+
* <li>Map back all residues in a multiple alignment of the repeats.
6464
* <li>Run a final optimization of all symmetric units correctly superimposed.
6565
* </ul>
6666
* </li>
@@ -97,7 +97,7 @@ public CeSymmIterative(CESymmParameters param) {
9797
/**
9898
* This method uses iteratively CeSymm to calculate all symmetries in the
9999
* input array of atoms and organize them in a multiple alignment of the
100-
* subunits.
100+
* repeats.
101101
*
102102
* @param atoms
103103
* atoms
@@ -171,7 +171,7 @@ private boolean iterate(Atom[] atoms) throws StructureException {
171171
else if (!r.isSignificant())
172172
return !levels.isEmpty();
173173

174-
// Generate the Atoms of one of the symmetric subunit
174+
// Generate the Atoms of one of the symmetric repeat
175175
Integer start = null;
176176
int it = 0;
177177
while (start == null) {
@@ -208,7 +208,7 @@ else if (!r.isSignificant())
208208
}
209209
}
210210

211-
// Iterate further on those Atoms (of the first subunit only)
211+
// Iterate further on those Atoms (of the first repeat only)
212212
levels.add(r.getMultipleAlignment());
213213
return iterate(atomsR);
214214
}
@@ -295,9 +295,9 @@ private void recoverAxes() {
295295
parents *= subsize;
296296
size /= subsize;
297297

298-
List<Integer> subunitTransform = new ArrayList<Integer>();
298+
List<Integer> repeatTransform = new ArrayList<Integer>();
299299
for (int i = 0; i < size * parents; i++) {
300-
subunitTransform.add(0);
300+
repeatTransform.add(0);
301301
}
302302

303303
List<List<Integer>> superpose = new ArrayList<List<Integer>>();
@@ -315,19 +315,19 @@ private void recoverAxes() {
315315

316316
for (int p = 0; p < parents; p++) {
317317
for (int s = 0; s < size; s++) {
318-
subunitTransform.set(p * size + s, p % subsize);
318+
repeatTransform.set(p * size + s, p % subsize);
319319
}
320320
}
321-
axes.addAxis(axis, superpose, subunitTransform, subsize);
321+
axes.addAxis(axis, superpose, repeatTransform, subsize);
322322
}
323323
result.setAxes(axes);
324324
}
325325

326326
/**
327-
* Calculate the number of helix and strand SSE of a subunit.
327+
* Calculate the number of helix and strand SSE of a repeat.
328328
*
329329
* @param atoms
330-
* Atom array of the subunit found
330+
* Atom array of the repeat found
331331
* @return int number of helix or strand SSE
332332
*/
333333
private static int countHelixStrandSSE(Atom[] atoms) {

biojava-structure/src/main/java/org/biojava/nbio/structure/symmetry/internal/CeSymmResult.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -82,12 +82,12 @@ else if (multipleAlignment
8282
}
8383

8484
/**
85-
* Return the symmetric protodomains as structure identifiers.
85+
* Return the symmetric repeats as structure identifiers.
8686
*
8787
* @return List of StructureIdentifiers
8888
* @throws StructureException
8989
*/
90-
public List<StructureIdentifier> getProtodomains()
90+
public List<StructureIdentifier> getRepeatsID()
9191
throws StructureException {
9292

9393
List<StructureIdentifier> protodomains = new ArrayList<StructureIdentifier>(
@@ -100,7 +100,7 @@ public List<StructureIdentifier> getProtodomains()
100100
Block align = multipleAlignment.getBlocks().get(0);
101101

102102
for (int su = 0; su < symmOrder; su++) {
103-
// Get the start and end residues of the subunit
103+
// Get the start and end residues of the repeat
104104
ResidueNumber res1 = atoms[align.getStartResidue(su)].getGroup()
105105
.getResidueNumber();
106106
ResidueNumber res2 = atoms[align.getFinalResidue(su)].getGroup()

biojava-structure/src/main/java/org/biojava/nbio/structure/symmetry/internal/ResidueGroup.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* component of the self-Alignment Graph in symmetry analysis.
1111
* <p>
1212
* This class provides an interface for comparing and combining them to refine
13-
* self-Alignments into consistent MultipleAlignments of subunits.
13+
* self-Alignments into consistent MultipleAlignments of repeats.
1414
*
1515
* @author Aleix Lafita
1616
* @since 4.2.0
@@ -48,7 +48,7 @@ public int order() {
4848
* <pre>
4949
* Two maximally connected components of the self-alignment Graph are
5050
* compatible if they can be combined in a consistent multiple alignment
51-
* of subunits, i.e.there exists one residue in c1 between each sorted
51+
* of repeats, i.e.there exists one residue in c1 between each sorted
5252
* pair of residues in c2.
5353
* </pre>
5454
*

biojava-structure/src/main/java/org/biojava/nbio/structure/symmetry/internal/SequenceFunctionRefiner.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838

3939
/**
4040
* Creates a refined alignment with the CE-Symm alternative self-alignment.
41-
* Needs the order of symmetry and assumes that the last subunit aligns
41+
* Needs the order of symmetry and assumes that the last repeat aligns
4242
* with the first, being thus a CLOSE symmetry.
4343
*
4444
* @author Spencer Bliven
@@ -441,7 +441,7 @@ private static AFPChain partitionAFPchain(AFPChain afpChain,
441441
Atom[] ca1, Atom[] ca2, int order) throws StructureException{
442442

443443
int[][][] newAlgn = new int[order][][];
444-
int subunitLen = afpChain.getOptLength()/order;
444+
int repeatLen = afpChain.getOptLength()/order;
445445

446446
//Extract all the residues considered in the first chain of the alignment
447447
List<Integer> alignedRes = new ArrayList<Integer>();
@@ -454,12 +454,12 @@ private static AFPChain partitionAFPchain(AFPChain afpChain,
454454
//Build the new alignment
455455
for (int su=0; su<order; su++){
456456
newAlgn[su] = new int[2][];
457-
newAlgn[su][0] = new int[subunitLen];
458-
newAlgn[su][1] = new int[subunitLen];
459-
for (int i=0; i<subunitLen; i++){
460-
newAlgn[su][0][i] = alignedRes.get(subunitLen*su+i);
457+
newAlgn[su][0] = new int[repeatLen];
458+
newAlgn[su][1] = new int[repeatLen];
459+
for (int i=0; i<repeatLen; i++){
460+
newAlgn[su][0][i] = alignedRes.get(repeatLen*su+i);
461461
newAlgn[su][1][i] = alignedRes.get(
462-
(subunitLen*(su+1)+i)%alignedRes.size());
462+
(repeatLen*(su+1)+i)%alignedRes.size());
463463
}
464464
}
465465

0 commit comments

Comments
 (0)