use dist instead of step for peak merging