A Smart method to Select the Highest and Lowest Pitches in MIDI

All but the octave and ‘from top’ parameter already exist in context variables.