title: Converting value of a dictionary of lists to floats
body: <p>Newbie to Python here! I could really do with some help on a sentiment project I'm doing in Python.</p>
  <p>I've build this dictionary which I'd like to use to go through comments I've scraped from a Guardian article. I want to add an extra column to the <code>guardian_comments</code> dataframe which signifies whether the value in the <code>sentiment_score</code> column is very_negative, negative, neutral, positive or very_positive:</p>
  <pre class="lang-py prettyprint-override"><code>lookup_dict = {
  &quot;very_negative&quot;:[-0.9, -0.8, -0.7, -0.6], 
  &quot;negative&quot;:[-0.5, -0.4, -0.3, -0.2, -0.1],
  &quot;neutral&quot;:[0],
  &quot;positive&quot;:[0.1, 0.2, 0.3, 0.4, 0.5], 
   &quot;very_positive&quot;:[0.6, 0.7, 0.8, 0.9, 1]}
  
  guardian_comments['sentiment_level'] = guardian_comments['sentiment_score'].map(lambda x: lookup_dict[x])
  </code></pre>
  <p>However, I'm receiving a <code>KeyError</code> which I think is down to the fact the dictionary lists haven't been converted to floats. Can anyone advise me on how to do this?</p>
  <p>Thank you!</p>