% have For each Method 2 is based on DP. % Given a fixed number of notes, we can use DP to find the optimum assignment of pitch to note. % Hence for a given L-1 distance threshold, we can increase the numbrer of notes incrementally, % until the distance returned by DP is smaller than the threshold. opt.method='dp'; figure; note02=pv2note(pv, opt, 1); %% % Method 3 is based on HMM: opt.method='hmm'; figure; note03=pv2note(pv, opt, 1);