Function heuristic_3(DataSetFid&, Parameters&, const std::vector<std::vector<double>>&)

Function Documentation

std::vector<Rule> heuristic_3(DataSetFid &trainDataset, Parameters &p, const std::vector<std::vector<double>> &hyperlocus)

Generates a list of rules covering all training samples. This is the fastest heuristic but cannot be parallelized.

Fastest heuristic that selects a random sample in the not covered ones, computes its rule, adds it to the computed rules, and removes each sample covered by this rule. When all samples are covered, it removes duplicates.

Parameters:
  • trainDataset – Class containing all usable data to compute the algorithm.

  • p – Class containing all user-defined parameters that influences the program execution.

  • hyperlocus – 2D vector of doubles representing all the possible hyperplanes used to compute the Fidex algorithm.

Returns:

A vector containing the computed rules.