title: R: dplyr- error in using recode function
body: <p>I am new to R and trying to recode ordinal variables to numeric values.  i have a variable named 'Founders_previous_company_employee_count' having 3 different entries as inputs-("Small","Medium","Large") which i am recording it to 1,2,3 values respectively.
  I tried using revalue function from plyr package using the below code</p>
  
  <pre><code>startupfull$employee_count_code&lt;-as.numeric(revalue(startupfull$Founders_previous_company_employee_count,c("Small"=1, "Medium"=2, "Large"=3))) 
  </code></pre>
  
  <p>which works fine.
  However, i try using recode function in dplyr package, I am getting error message.</p>
  
  <p>Code: </p>
  
  <pre><code>startupfull$prevcomp_empcount_code &lt;-  as.numeric(recode(startupfull$Founders_previous_company_employee_count,c("Small"=1, "Medium"=2, "Large"=3)))
  </code></pre>
  
  <blockquote>
    <p>Error- Error: All replacements must be named</p>
  </blockquote>
  
  <p>What am I doing wrong here?</p>