title: Re-arrange multiple columns in a data set into one column using R
body: <p>I would like to combine three columns in one of my data sets into one with variable name "al_anim" and remove any duplicates, rank the values (animal ids) from lowest to highest, and re-number each animal from 1 to N under the variable name "new_id".</p>
  
  <pre><code> anim1 &lt;- c(1456,2569,5489,1456,4587)
   anim2 &lt;- c(6531,6987,6987,15487,6531)
   anim3 &lt;- c(4587,6548,7894,3215,8542)
   mydf &lt;- data.frame(anim1,anim2,anim3)
  </code></pre>
  
  <p>Any help would be very much appreciated!</p>
  
  <p>Baz</p>