Sandeep

It would be nice to set stall generations and parameters.  I implemented a quick
hack method which may suffice for your problem.  I made a static variable in the
class that evaluates the individual (in your case you may want to call it
'best_solution'.  Now you can, for example, just make an "if" statement that
determines if a "stop_variable" is true.  Make the "stop_variable" type boolean
and pass it to the fitness() function (it will be the last variable the fitness
function takes in.  Anyways, this is a hack method.  I haven't taken the trouble
took look into a good solution, but if you find one, please tell me.  I think
that this is an very nice feature to have in a GA.

Robert HovdenQuoting Sandeep Mulgund <[log in to unmask]>:

> Is there any way to encode in ECJ some stopping criteria other than the
> maximum number of generations?  For example, what if I wanted to give up if
> I don't get more than x% improvement in the best solution over y
> generations?
>
> Sandeep
>


--