I apologize, the line:
Distribution[] dists = distOverAlignment2(align, false, 0.01);

should actually be:
Distribution[] dists = DistributionTools.distOverAlignment(align, false, 0.01);


Thank you.

Alberto Ambesi


On 3 Dec 2003, at 09:55, David Huen wrote:


On Tuesday 02 Dec 2003 4:49 pm, Alberto Ambesi wrote:
hi, I found this bug when using Distrubutions iteratively many times.
The problem is that when creating Distrubution objects iteratively
computation time for each iteration increases with time.

this is a piece of code that demonstrates the issue:

public class DistributionTest {
     public static void main(String[] args) throws Exception{
         long timePoint = System.currentTimeMillis();
         for (int i=0; i<2500; i++) {
             Map map = new HashMap();
             map.put("seq0", DNATools.createDNA("aggag"));
             map.put("seq1", DNATools.createDNA("aggaa"));
             map.put("seq2", DNATools.createDNA("aggag"));
             map.put("seq3", DNATools.createDNA("aagag"));
             Alignment align = new SimpleAlignment(map);
             Distribution[] dists = distOverAlignment2(align, false,
0.01);
             long previousPoint = timePoint;
             timePoint = System.currentTimeMillis();
             System.out.println(timePoint - previousPoint);
         }
     }
}


Could you provide the source to distOverAlignment2 so it becomes clear what
it is doing?


Thanks,
David Huen


_______________________________________________ Biojava-l mailing list - [EMAIL PROTECTED] http://biojava.org/mailman/listinfo/biojava-l

Reply via email to