[エラー] 'シリーズをクラス' float 'に変換できません



Can Not Convert Series Classfloat



def is_number(s): try: float(s) return True except ValueError: pass try: import unicodedata unicodedata.numeric(s) return True except (TypeError, ValueError): pass return False def weihao(a): if is_number(a.str.slice(6,7))==True: return a.str.slice(6,7) elif is_number(a.str.slice(5,6))==True: return a.str.slice(5,6) elif is_number(a.str.slice(4,5))==True: return a.str.slice(4,5) elif is_number(a.str.slice(3,4))==True: return a.str.slice(3,4) Gather0901['Ending'] = Summary0901.apply(lambda x: weihao (Summary0901.License plate number), axis = 1) TypeError: ('cannot convert the series to ', 'occurred at index 0')

シリーズをに変換できません