title: How can i filter a dataframe's rows by specific bins
body: <p>Suppose I have a data frame:</p>
  
  <pre><code>col1  col2
  15    2
  17    4
  14    5
  20    10
  21    11
  19    11
  18    12
  20    6
  22    7
  21    8
  22    8
  25    6
  21    7
  </code></pre>
  
  <p>First, I use <code>pandas.value_counts()</code> for <code>col2</code> and I use three bins <code>(0,5] (5,10] (10,15]</code>. </p>
  
  <p>Then, I want to filter the rows where the <code>col2</code> values belong to the first two bins with the highest frequency, in this case bins <code>(5,10]</code> and <code>(10,15]</code>.</p>