title: Create dictionary from panda series with multiple values
body: <p>I have a pd dataframe as follow:</p>
  
  <pre><code>df=pd.DataFrame([['A',1],['A',3],['B',2],['B',5],['C',8]],columns=['k','v'])
  </code></pre>
  
  <p>And from I would like to create the following dictionary:</p>
  
  <pre><code>{'A':[1,3],
   'B':[2,5],
   'C':[8]
  }
  </code></pre>
  
  <p>I am currently doing it with: </p>
  
  <pre><code>from collections import defaultdict
  
  
  my_dict=defaultdict(list)
  
  for key in df.k:
      my_dict[key].append(df['v'][df['k']==key])
  </code></pre>
  
  <p>But it is not efficient (very time consuming) for large df and also sends me back the index of the values, which I do not want.</p>
  
  <p>Any suggestions?</p>
  
  <p>Thanks</p>