git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
remove system.out
[jalview.git]
/
src
/
jalview
/
analysis
/
Dna.java
diff --git
a/src/jalview/analysis/Dna.java
b/src/jalview/analysis/Dna.java
index
836c39e
..
5096ae8
100644
(file)
--- a/
src/jalview/analysis/Dna.java
+++ b/
src/jalview/analysis/Dna.java
@@
-197,28
+197,36
@@
public class Dna {
if (annotations[i].autoCalculated) {
\r
continue;
\r
}
\r
if (annotations[i].autoCalculated) {
\r
continue;
\r
}
\r
-
\r
- aSize = aslen; // aa alignment width.
\r
- jalview.datamodel.Annotation[] anots =
\r
- new jalview.datamodel.Annotation[aSize];
\r
\r
\r
- for (a = 0; a < aSize; a++)
\r
+ aSize = aslen; // aa alignment width.
\r
+ jalview.datamodel.Annotation[] anots =
\r
+ (annotations[i].annotations==null)
\r
+ ? null :
\r
+ new jalview.datamodel.Annotation[aSize];
\r
+ if (anots!=null)
\r
{
\r
{
\r
- // process through codon map.
\r
- if (codons[a]!=null && codons[a][0]==(codons[a][2]-2))
\r
+ for (a = 0; a < aSize; a++)
\r
{
\r
{
\r
- pos = codons[a][0];
\r
- if (annotations[i].annotations[pos] == null
\r
- || annotations[i].annotations[pos] == null)
\r
- continue;
\r
+ // process through codon map.
\r
+ if (codons[a]!=null && codons[a][0]==(codons[a][2]-2))
\r
+ {
\r
+ pos = codons[a][0];
\r
+ if (annotations[i].annotations[pos] == null
\r
+ || annotations[i].annotations[pos] == null)
\r
+ continue;
\r
\r
\r
- anots[a] = new Annotation(annotations[i].annotations[pos]);
\r
+ anots[a] = new Annotation(annotations[i].annotations[pos]);
\r
+ }
\r
}
\r
}
\r
\r
jalview.datamodel.AlignmentAnnotation aa
\r
= new jalview.datamodel.AlignmentAnnotation(annotations[i].label,
\r
annotations[i].description, anots);
\r
}
\r
}
\r
\r
jalview.datamodel.AlignmentAnnotation aa
\r
= new jalview.datamodel.AlignmentAnnotation(annotations[i].label,
\r
annotations[i].description, anots);
\r
+ if (annotations[i].hasScore)
\r
+ {
\r
+ aa.setScore(annotations[i].getScore());
\r
+ }
\r
al.addAnnotation(aa);
\r
}
\r
}
\r
al.addAnnotation(aa);
\r
}
\r
}
\r