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
formatting
[jalview.git]
/
src
/
jalview
/
analysis
/
AAFrequency.java
diff --git
a/src/jalview/analysis/AAFrequency.java
b/src/jalview/analysis/AAFrequency.java
index
f409f8c
..
4a68f81
100755
(executable)
--- a/
src/jalview/analysis/AAFrequency.java
+++ b/
src/jalview/analysis/AAFrequency.java
@@
-53,6
+53,11
@@
public class AAFrequency
\r
Hashtable [] reply = new Hashtable[width];
\r
\r
\r
Hashtable [] reply = new Hashtable[width];
\r
\r
+ if(end>=width)
\r
+ {
\r
+ end = width;
\r
+ }
\r
+
\r
calculate(seqs, start, end, reply);
\r
\r
return reply;
\r
calculate(seqs, start, end, reply);
\r
\r
return reply;
\r
@@
-68,9
+73,9
@@
public static final void calculate(SequenceI[] sequences,
char c;
\r
float percentage;
\r
\r
char c;
\r
float percentage;
\r
\r
- int[] values = new int[132];
\r
+ int[] values = new int[255];
\r
\r
\r
- String seq;
\r
+ char [] seq;
\r
\r
for (i = start; i < end; i++)
\r
{
\r
\r
for (i = start; i < end; i++)
\r
{
\r
@@
-78,14
+83,14
@@
public static final void calculate(SequenceI[] sequences,
maxCount = 0;
\r
maxResidue = "";
\r
nongap = 0;
\r
maxCount = 0;
\r
maxResidue = "";
\r
nongap = 0;
\r
- values = new int[132];
\r
+ values = new int[255];
\r
\r
for (j = 0; j < jSize; j++)
\r
{
\r
seq = sequences[j].getSequence();
\r
\r
for (j = 0; j < jSize; j++)
\r
{
\r
seq = sequences[j].getSequence();
\r
- if (seq.length() > i)
\r
+ if (seq.length > i)
\r
{
\r
{
\r
- c = seq.charAt(i);
\r
+ c = seq[i];
\r
\r
if(c == '.' || c==' ')
\r
c = '-';
\r
\r
if(c == '.' || c==' ')
\r
c = '-';
\r