title: How to group by one column and sort the values of another column?
body: <p>Here is my dataframe</p>
  
  <pre><code>import pandas as pd
  df = pd.DataFrame({'A': ['one', 'one', 'two', 'two', 'one'] ,
                     'B': ['Ar', 'Br', 'Cr', 'Ar','Ar'] ,
                     'C': ['12/15/2011', '11/11/2001', '08/30/2015', '07/3/1999','03/03/2000' ],
                        'D':[1,7,3,4,5]})
  </code></pre>
  
  <p>My goal is to group by column <code>A</code> and sort within grouped results by column <code>B</code>. </p>
  
  <p>Here is what I came up with:</p>
  
  <pre><code>sort_group = df.sort_values('B').groupby('A')
  </code></pre>
  
  <p>I was hoping that grouping operation would not distort order, but it does not work and also returns not a dataframe, but <code>groupby</code> object</p>
  
  <pre><code>&lt;pandas.core.groupby.DataFrameGroupBy object at 0x0000000008B190B8&gt;
  </code></pre>
  
  <p>Any suggestions?</p>