Converted selectedModes to be a list of 1-based indices named selectedModeNumbers