title: Unlist a dataframe variable in R
body: <p>I have a dataframe bask.df as below.</p>
  
  <pre><code>     basko1 basko2 
  1st       6      1 
  2nd      12      1 
  3rd       8      8 
  4th       4      5 
  5th       1      2 
  6th       8      9 
  7th       1      2 
  8th       8      9 
  9th      12     14 
  10th     15     10 
  11th      3      6 
  12th      5      2 
  13th      4      6 
  14th      3      1 
  15th      4      6 
  16th      3      1 
  </code></pre>
  
  <p>I want to add a third column named total, which is the sum of the integers in basko1 and basko2 columns. </p>
  
  <p>When I try in R as :</p>
  
  <pre><code>bask.df['total'] &lt;- as.numeric(bask.df['basko1']) + as.numeric(bask.df['basko2']) , 
  </code></pre>
  
  <p>it gives me the error as</p>
  
  <p><code>Error: (list) object cannot be coerced to type 'double'</code></p>
  
  <p>Is bask.df[basko1] and bask.df[basko2], which are seemingly vectors, actually present as lists here ? Or I am doing anything else wrong ?</p>