title: Pandas dataframe perform calculations on duplicate rows
body: <p>I have a dataframe with millions of rows of ad ids scraped from a website on consecutive days, in the format:</p>
  
  <pre><code>ad-id           Date scraped
  SSE-AD-3469148  15-Apr
  OAG-AD-12583686 15-Apr
  OAG-AD-10476872 15-Apr
  SSE-AD-3037758  15-Apr
  OAG-AD-12583686 16-Apr
  OAG-AD-10476872 16-Apr
  SSE-AD-3037758  16-Apr
  OAG-AD-10476872 17-Apr
  SSE-AD-3037758  17-Apr
  </code></pre>
  
  <p>I want to output unique ad ids only, however I need to know the start and end scrape date for each ad id, like so:</p>
  
  <pre><code>ad-id           First scrape    Last Scrape
  SSE-AD-3469148  15-Apr          15-Apr
  OAG-AD-12583686 15-Apr          16-Apr
  OAG-AD-10476872 15-Apr          17-Apr
  SSE-AD-3037758  15-Apr          17-Apr
  </code></pre>
  
  <p>What is the most time efficient way of producing this using Pandas? I can only think of ways involving loops which for a few million rows will be very slow.</p>