round2 | R Documentation |
R “rounds to even” when rounding off a 5. This formula rounds numbers ending in .5 up ("rounding in commerce"). This formula is based on http://alandgraf.blogspot.com/2012/06/rounding-in-r.html
round2(x, digits = 1)
x |
a numeric vector |
digits |
integer indicating the number of decimal places |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.