title: Pandas 'count(distinct)' equivalent
body: <p>I am using Pandas as a database substitute as I have multiple databases (<a href="https://en.wikipedia.org/wiki/Oracle_Database" rel="nofollow noreferrer">Oracle</a>, <a href="https://en.wikipedia.org/wiki/Microsoft_SQL_Server" rel="nofollow noreferrer">SQL Server</a>, etc.), and I am unable to make a sequence of commands to a SQL equivalent.</p>
  <p>I have a table loaded in a DataFrame with some columns:</p>
  <pre class="lang-none prettyprint-override"><code>YEARMONTH, CLIENTCODE, SIZE, etc., etc.
  </code></pre>
  <p>In SQL, to count the amount of different clients per year would be:</p>
  <pre class="lang-sql prettyprint-override"><code>SELECT count(distinct CLIENTCODE) FROM table GROUP BY YEARMONTH;
  </code></pre>
  <p>And the result would be</p>
  <pre class="lang-none prettyprint-override"><code>201301    5000
  201302    13245
  </code></pre>
  <p>How can I do that in Pandas?</p>