title: How to assign a name to the size() column?
body: <p>I am using <code>.size()</code> on a groupby result in order to count how many items are in each group.</p>
  <p>I would like the result to be saved to a new column name without manually editing the column names array, how can it be done?</p>
  <p>This is what I have tried:</p>
  <pre><code>grpd = df.groupby(['A','B'])
  grpd['size'] = grpd.size()
  grpd
  </code></pre>
  <p>and the error I got:</p>
  <blockquote>
  <p>TypeError: 'DataFrameGroupBy' object does not support item assignment
  (on the second line)</p>
  </blockquote>