title: R: Unused argument error in round
body: <p>I have a data.frame mdf that looks like this; </p>
  
  <pre><code>       date     time moon Sunrise Sunset            time.tmp
  1    1.9.12  0:00:00 0.00    6:52  20:26 2013-06-12 00:00:00
  2    1.9.12  1:00:00 0.00    6:52  20:26 2013-06-12 01:00:00
  3    1.9.12  2:00:00 0.00    6:52  20:26 2013-06-12 02:00:00
  4    1.9.12  3:00:00 0.00    6:52  20:26 2013-06-12 03:00:00
  5    1.9.12  4:00:00 0.00    6:52  20:26 2013-06-12 04:00:00
  </code></pre>
  
  <p>when I try to use round() on the Sunrise and Sunset columns I get an error 'unused argument'. 
  I can't see why. </p>
  
  <p>This is the line of code I'm using;</p>
  
  <pre><code>round(strptime(mdf$Sunrise, format="%H:%M"), units = "hours")
  </code></pre>
  
  <p>and this is the error:</p>
  
  <pre><code>Error in round.POSIXt(list(sec = c(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,  : 
    unused argument (units = "hours")
  </code></pre>
  
  <p>If I use this</p>
  
  <pre><code>round(strptime("6:52", format="%H:%M"), units="hours")
  </code></pre>
  
  <p>I get this error in return</p>
  
  <pre><code>Error in round.POSIXt(list(sec = 0, min = 52L, hour = 6L, mday = 12L,  : 
    unused argument (units = "hours")
  </code></pre>
  
  <p>SessionInfo() returns </p>
  
  <pre><code>R version 3.0.1 (2013-05-16)
  Platform: x86_64-apple-darwin10.8.0 (64-bit)
  </code></pre>
  
  <p>Any suggestions as to how to solve this error? </p>
  
  <p>This line of code is part of what was suggested in another question asked here; <a href="https://stackoverflow.com/questions/17043864/place-1-heatmap-on-another-with-transparency-in-r">Place 1 heatmap on another with transparency in R</a></p>