Hello everyone, I am currently working on a large dataset that mainly consists of floating-point numbers with many digits. However, I am facing processing issues as the dataset is taking up a lot of memory space. I suspect that the large number of floating-point figures in the dataset is the reason behind this issue.
For example, I have numbers like:
583.9102441
And I want to represent them as:
583.91
Is there a way to limit the number of decimal places to reduce memory usage? Can I round off or truncate (drop) the extra digits from the number completely?
Please provide me with different methods and their corresponding codes that I can use to achieve this. Thank you!