Learn R Programming

SIMPLICA (version 1.0.0)

SCAMonitorFactory: Simplivariate Component Analysis monitoring function factory for GA progress

Description

Creates a monitoring function that prints the current generation and the best fitness score to the console at specified intervals. Intended for use as a monitor function in GA runs.

Usage

SCAMonitorFactory(interval = 100)

Value

A monitoring function that can be used with GA. The returned function takes a GA object and prints progress information at the specified interval.

Arguments

interval

An integer specifying the interval for printing progress updates. Default is 100 (prints every 100 generations).

Examples

Run this code
# Create monitor that prints every 100 generations (default)
monitor <- SCAMonitorFactory()
# ga(..., monitor = monitor)

# Create monitor that prints every 50 generations
monitor <- SCAMonitorFactory(50)
# ga(..., monitor = monitor)

Run the code above in your browser using DataLab