A "Pitch stability" measure can be made by measuring the longest hold time for any pitch. That means fast melodies (or sloppy pitch tracking) give low stability. Long held notes give high stability (allowing for some spurious tracker errors, since we only measure longer held pitches. Question is how wide tolerance we allow for "same pitch"? Try first that max deviation is one semitone (not same pitch if deviation exceed threshold)
A "Pitch stability" measure can be made by measuring the longest hold time for any pitch. That means fast melodies (or sloppy pitch tracking) give low stability. Long held notes give high stability (allowing for some spurious tracker errors, since we only measure longer held pitches. Question is how wide tolerance we allow for "same pitch"? Try first that max deviation is one semitone (not same pitch if deviation exceed threshold)