I have a .txt file. I have opened it in Notepad++ and verified one of the columns has float numbers i.e. 1519.75, 1519.25.
What do I need to do in order to avoid rounding? I have other files which work fine, but not this one.
My code uses below:
pd.set_option('display.float_format', '{:.2f}'.format)
raw_df = pd.read_csv(file, sep='t', float_precision='round_trip')
I have tried using pd.set_option as well as pd.read_csv with float_precision = ’round_trip’, but the raw_df output will show the values as 1519.8, 1519.2