anchor.diff:    });
   });
   </script>
  -<div id="mouse-avg"></div>
   </body>
   </html>
  
positive.code:     startX = parseInt($('#iframe').contents().find('#sel-start').css('left'));
      stopX = parseInt($('#iframe').contents().find('#sel-stop').css('left'));
      pitch_sel = pitch.filter(function(el, idx) { return idx >= startX && idx <= stopX; });
      avg_data = '';
      if (pitch_sel.length > 0) {
        avg_data += 'Avg. pitch: <span style="width: auto; color: black">' + (pitch_sel.reduce(function(a, b) { return a + b; }) / pitch_sel.length).toFixed(2) + '</span>';
      }
      formants_sel = formants.filter(function(el, idx) { return idx >= startX && idx <= stopX; });
      if (formants_sel.length > 0) {
  
negative.code:    %><img id='small<%= i %>' src='<%= @conf['output_dir'] %>/<%= basename %>-wave.jpg' width='<%= width %>%' height='70' style='display:none'><%
     end
   %>
   <div style="background-color: #999; color: #fff; font-size: 80%; font-family: monaco,'VT-100','lucida console',courier,system;" id="mouse-avg"></div>
   <iframe id='iframe' height="237" width="100%" style="border: 0"></iframe>
  <script type="text/javascript">
  var scrollMode = false;
  