From 4d9f4a0d2e189d30b29dc001de6512f5cd1292fb Mon Sep 17 00:00:00 2001 From: Muhammad Yasirroni <48709672+yasirroni@users.noreply.github.com> Date: Sat, 1 Jul 2023 10:41:18 +0700 Subject: [PATCH] add ga_instance.last_generation_fitness to pygad.rst --- docs/source/pygad.rst | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/source/pygad.rst b/docs/source/pygad.rst index 73d1ef6a..151f1465 100644 --- a/docs/source/pygad.rst +++ b/docs/source/pygad.rst @@ -909,7 +909,9 @@ It accepts the following parameters: - ``pop_fitness=None``: An optional parameter that accepts a list of the fitness values of the solutions in the population. If ``None``, then the ``cal_pop_fitness()`` method is called to calculate the - fitness values of the population. + fitness values of the ``self.population``. Use + ``ga_instance.last_generation_fitness`` to use latest fitness value + and skip recalculation of the population fitness. It returns the following: