I'm making using a panda frame containing columns like below:
data = {'chindice': [ '-1', '5.89 e-06', '6.76 e-06', '6.31 e-06', '1',
'4', np.nan],
'target': ['classe1', 'classe2', 'classe3', np.nan,'classe5', 'classe4', 'classe5' ],
}
df = pd.DataFrame(data)
I need to use the columns "chindice" as float, but I couldnt because the columns dtype is 'object'. Any help would be appreciated. I am a newbie to pandas. Thanks