pyarrow.compute.round#
- pyarrow.compute.round(x,/,ndigits=0,round_mode='half_to_even',*,options=None,memory_pool=None)#
Round to a given precision.
Options are used to control the number of digits and rounding mode.Default behavior is to round to the nearest integer anduse half-to-even rule to break ties.
- Parameters:
- xArray-like or scalar-like
Argument to compute function.
- ndigits
int, default 0 Number of fractional digits to round to.
- round_mode
str, default “half_to_even” Rounding and tie-breaking mode.Accepted values are “down”, “up”, “towards_zero”, “towards_infinity”,“half_down”, “half_up”, “half_towards_zero”, “half_towards_infinity”,“half_to_even”, “half_to_odd”.
- options
pyarrow.compute.RoundOptions, optional Alternative way of passing options.
- memory_pool
pyarrow.MemoryPool, optional If not passed, will allocate memory from the default memory pool.
On this page

