Skip to main content

round

_.round(number) # Ⓢ [Ⓣ][1] Ⓝ

Computes number rounded to precision.

Since​

3.10.0

Arguments​

  1. number (number): The number to round.

Returns​

(number): Returns the rounded number.

Example​

_.round(4.006);
// => 4

_.round([4.006, 2]);
// => 4.01

_.round([4060, -2]);
// => 4100