Skip to main content
. 2022 May 14;22(10):3737. doi: 10.3390/s22103737
Algorithm 2 Pseudocode Implemented for forward Sequential Selection
SPACE = 1…L                //L = number of total features.
EXIT = false
WHILE NOT EXIT
FOR i =1 TO |SPACE|
TEMP(i) = J(SUBSET V SPACE(i))       //TEMP = Temporal variable.
END
BEST_i = ARGMAX(TEMP)        //The maximum value of the
                        //TEMP vector is stored in BEST.
IF TEMP(BEST_i) > BEST_EVAL        //Comparison between the best stored
SUBSET = [SUBSET, SPACE(BEST_i)]     //evaluation and the best evaluation
BEST_EVAL = TEMP(BEST_i)         //of the new subset.
SPACE = SPACE-SPACE(BEST_i)
ELSE
OUTPUT = true
END
END
RETURN SUBSET, BEST_EVAL