Pandas : TypeError: float() argument must be a string or a number

后端 未结 1 790
一整个雨季
一整个雨季 2020-12-16 01:56

I have a dataframe that contains

user_id    date       browser  conversion  test  sex  age  country
   1    2015-12-03       IE        1         0    M   32         


        
相关标签:
1条回答
  • 2020-12-16 02:35

    IIUC you need exclude column date also:

    columns = [c for c in columns if c not in ["test", 'date']]
    

    because error:

    TypeError: float() argument must be a string or a number, not 'Timestamp'

    0 讨论(0)
提交回复
热议问题