title: How to conditionally remove duplicates from a pandas dataframe
body: <p>Consider the following dataframe</p>
  
  <pre><code>import pandas as pd
  df = pd.DataFrame({'A' : [1, 2, 3, 3, 4, 4, 5, 6, 7],
                     'B' : ['a','b','c','c','d','d','e','f','g'],
                     'Col_1' :[np.NaN, 'A','A', np.NaN, 'B', np.NaN, 'B', np.NaN, np.NaN],
                     'Col_2' :[2,2,3,3,3,3,4,4,5]})
  df
  Out[92]: 
      A  B Col_1  Col_2
   0  1  a   NaN      2
   1  2  b     A      2
   2  3  c     A      3
   3  3  c   NaN      3
   4  4  d     B      3
   5  4  d   NaN      3
   6  5  e     B      4
   7  6  f   NaN      4
   8  7  g   NaN      5
  </code></pre>
  
  <p>I want to remove all rows which are duplicates with regards to column <code>'A' 'B'</code>. I want to remove the entry which has a <code>NaN</code> entry (I know that for all dulicates there will be a <code>NaN</code> and a not-<code>NaN</code> entry). The end results should look like this</p>
  
  <pre><code>    A  B Col_1  Col_2
   0  1  a   NaN      2
   1  2  b     A      2
   2  3  c     A      3
   4  4  d     B      3
   6  5  e     B      4
   7  6  f   NaN      4
   8  7  g   NaN      5
  </code></pre>
  
  <p>All efficient, one-liners are most welcome</p>