help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Watching the best fitness in each generation in ga


From: Hamed Abdy
Subject: Re: Watching the best fitness in each generation in ga
Date: Wed, 9 May 2012 10:33:54 +0430


On Wed, May 9, 2012 at 3:17 AM, Jordi Gutiérrez Hermoso <address@hidden> wrote:
On 8 May 2012 16:53, Hamed Abdy <address@hidden> wrote:
> My question is about the ga command:
> Is it possible to get the best fitness of each generation in ga (for example
> for ploting it)?

From my understanding of it, the 6th output argument of ga contains
this information. So you can do,

   [x, ~, ~, ~, ~, fitness] = ga(stuff, more, stuff)

to get those values.

HTH,
- Jordi G. H.


Thank you, Jordi.
But the 6th output argument of ga just contains fitness of the last generation.
If you had 500 generations, it will only show the fitnesses (containing the best one) of all particles in the 500th generation.
My question is: how can we get the best fitness of all 500 generations?

Hamed Abdy

reply via email to

[Prev in Thread] Current Thread [Next in Thread]