title: How to parse a json column embedded in a pandas dataframe python
body: <p>I have a pandas dataframe <a href="http://pastebin.com/XBwJ4tBq" rel="nofollow">(raw csv file here)</a> which contains a couple of columns stored as json (d1 &amp; d2). How do I parse these columns to give me the required output of:  </p>
  
  <p><strong>2015-02-12,user1,05:15 | 20,16:30 | 20.0,22:00 | 10.0</strong></p>
  
  <p>I realise I have to transpose the output once successfully parsed,but I'm having problems in reading the json data contained in the dataframe column. Any help appreciated! Thanks</p>
  
  <pre><code>&gt;&gt;&gt; test = pd.read_csv('schedsample.csv',sep=',', header=0)
  &gt;&gt;&gt; test.head()
           date username                                                 d1  \
  0  2015-02-12    user1  {"d1":[{"tm":"05:15","t":"20.0"},{"tm":"16:30"...   
  1  2015-02-12    user1  {"d2":[{"tm":"06:15","t":"20.0"},{"tm":"08:00"...   
  2  2015-02-12    user1  {"d3":[{"tm":"07:15","t":"20.0"},{"tm":"09:00"...   
  3  2015-02-12    user1  {"d4":[{"tm":"08:15","t":"20.0"},{"tm":"07:00"...   
  
                                                    d2  
  0  {"d1":[{"tm":"05:15","t":"20.0"},{"tm":"16:30"...  
  1  {"d1":[{"tm":"05:15","t":"20.0"},{"tm":"16:30"...  
  2  {"d1":[{"tm":"05:15","t":"20.0"},{"tm":"16:30"...  
  3  {"d1":[{"tm":"05:15","t":"20.0"},{"tm":"16:30"...  
  &gt;&gt;&gt; import json as js
  &gt;&gt;&gt; js.loads(test['d1'])
  Traceback (most recent call last):
    File "&lt;stdin&gt;", line 1, in &lt;module&gt;
    File "/Users/khurampervez/anaconda/lib/python2.7/json/__init__.py", line 338, in loads
  return _default_decoder.decode(s)
    File "/Users/khurampervez/anaconda/lib/python2.7/json/decoder.py", line 366, in decode
  obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  TypeError: expected string or buffer`
  </code></pre>