title: pandas dataframe groupby datetime month
body: <p>Consider a csv file:</p>
  
  <pre><code>string,date,number
  a string,2/5/11 9:16am,1.0
  a string,3/5/11 10:44pm,2.0
  a string,4/22/11 12:07pm,3.0
  a string,4/22/11 12:10pm,4.0
  a string,4/29/11 11:59am,1.0
  a string,5/2/11 1:41pm,2.0
  a string,5/2/11 2:02pm,3.0
  a string,5/2/11 2:56pm,4.0
  a string,5/2/11 3:00pm,5.0
  a string,5/2/14 3:02pm,6.0
  a string,5/2/14 3:18pm,7.0
  </code></pre>
  
  <p>I can read this in, and reformat the date column into datetime format:</p>
  
  <pre><code>b=pd.read_csv('b.dat')
  b['date']=pd.to_datetime(b['date'],format='%m/%d/%y %I:%M%p')
  </code></pre>
  
  <p>I have been trying to group the data by month. It seems like there should be an obvious way of accessing the month and grouping by that. But I can't seem to do it. Does anyone know how?</p>
  
  <p>What I am currently trying is re-indexing by the date:</p>
  
  <pre><code>b.index=b['date']
  </code></pre>
  
  <p>I can access the month like so:</p>
  
  <pre><code>b.index.month
  </code></pre>
  
  <p>However I can't seem to find a function to lump together by month.</p>