# Round half up Error

**URL:** <https://discuss.python.org/t/round-half-up-error/22888>\
**Category:** Python Help\
**Created:** [January 18, 2023, 12:24am UTC](https://discuss.python.org/t/round-half-up-error/22888 "2023-01-18T00:24:20Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![MRAB](https://avatars.discourse-cdn.com/v4/letter/m/e9c0ed/32.png) [@MRAB](https://discuss.python.org/u/MRAB)\
**Post date:** [January 18, 2023, 1:11am UTC](https://discuss.python.org/t/round-half-up-error/22888/2 "2023-01-18T01:11:58Z")

</div>

Why are you using the Decimal module? It’s for fixed-point numbers and it doesn’t support what looks like numpy arrays or pandas dataframes.

Use numpy arrays have a `.round` method. Use that instead.

Incidentally, Python uses “banker’s rounding”, where you round to the nearest _even_ number. That’s because a half is _exactly_ between two numbers, so always rounding up would lead to a bias.

---

_[View the full topic](https://discuss.python.org/t/round-half-up-error/22888)._
