title: How do I create pandas DataFrame (with index or multiindex) from list of namedtuple instances?
body: <p>Simple example:</p>
  
  <pre><code>&gt;&gt;&gt; from collections import namedtuple
  &gt;&gt;&gt; import pandas
  
  &gt;&gt;&gt; Price = namedtuple('Price', 'ticker date price')
  &gt;&gt;&gt; a = Price('GE', '2010-01-01', 30.00)
  &gt;&gt;&gt; b = Price('GE', '2010-01-02', 31.00)
  &gt;&gt;&gt; l = [a, b]
  &gt;&gt;&gt; df = pandas.DataFrame.from_records(l, index='ticker')
  Traceback (most recent call last)
  ...
  KeyError: 'ticker'
  </code></pre>
  
  <p>Harder example:</p>
  
  <pre><code>&gt;&gt;&gt; df2 = pandas.DataFrame.from_records(l, index=['ticker', 'date'])
  &gt;&gt;&gt; df2
  
           0           1   2
  ticker  GE  2010-01-01  30
  date    GE  2010-01-02  31
  </code></pre>
  
  <p>Now it thinks that <code>['ticker', 'date']</code> is the index itself, rather than the columns I want to use as the index.</p>
  
  <p>Is there a way to do this without resorting to an intermediate numpy ndarray or using <code>set_index</code> after the fact?</p>