title: pandas: normalizing a DataFrame
body: <p>I have input data in a flattened file. I want to normalize this data, by splitting it into tables. Can I do that neatly with <code>pandas</code> - that is, by reading the flattened data into a <code>DataFrame</code> instance, and then applying some functions to obtain the resulting <code>DataFrame</code> instances?</p>
  
  <p>Example:</p>
  
  <p>Data is given to me on disk in the form of a CSV file like this:</p>
  
  <pre><code>ItemId   ClientId   PriceQuoted  ItemDescription
  1        1          10           scroll of Sneak
  1        2          12           scroll of Sneak
  1        3          13           scroll of Sneak
  2        2          2500         scroll of Invisible
  2        4          2200         scroll of Invisible
  </code></pre>
  
  <p>I want to create two DataFrames:</p>
  
  <pre><code>ItemId   ItemDescription
  1        scroll of Sneak
  2        scroll of Invisibile
  </code></pre>
  
  <p>and</p>
  
  <pre><code>ItemId   ClientId   PriceQuoted
  1        1          10
  1        2          12
  1        3          13
  2        2          2500
  2        4          2200
  </code></pre>
  
  <p>If <code>pandas</code> only has a good solution for the simplest case (normalization results in 2 tables with many-to-one relationship - just like in the above example), it might be enough for my current needs. I may need a more general solution in the future, however.</p>