src/GenFx.Components/Metrics/MaximumFitness.cs
/// <summary>
/// Calculates to determine the highest <see cref="GeneticEntity.ScaledFitnessValue"/> 
/// in the <paramref name="population"/>.
/// </summary>
/// <param name="population"><see cref="Population"/> from which to derive the metric.</param>
/// <returns>Largest value of <see cref="GeneticEntity.ScaledFitnessValue"/> found.</returns>
/// <exception cref="ArgumentNullException"><paramref name="population"/> is null.</exception>
Calculates to determine the highest
in the .
Calculates to determine the highest in the .
public override object? GetResultValue(Population population)
        {
            if (population == null)
            {
                throw new ArgumentNullException(nameof(population));
            }
            this.AssertIsInitialized();
            if (this.Algorithm!.FitnessScalingStrategy == null)
            {
                return population.RawMax;
            }
            return population.Entities.Max(e => e.ScaledFitnessValue);
        }
public override object ? GetResultValue ( Population population ) { if ( population == null ) { throw new ArgumentNullException ( nameof ( population ) ) ; } this . AssertIsInitialized ( ) ; if ( this . Algorithm ! . FitnessScalingStrategy == null ) { return population . RawMax ; } return population . Entities . Max ( e => e . ScaledFitnessValue ) ; }
Calculates to determine the highest
in the .
Calculates to determine the highest in the .
// If there's no fitness scaling, just use the raw max value.
Largest value of  found.
Largest value of found .
None
population
Population
from which to derive the metric.
from which to derive the metric .