Python for Data Analysis : Page 243 Modification
Post
원문 보기 →Python for Data Analysis : Page 243 Modification
Page 243. Original Source Code doesn't work, as it contains 'NaN' def to_cat_list(catstr): stripped=(x.strip() for x in catstr.split(',')) return [x for x in stripped if x] Error value : AttributeError: 'float' object has no attribute 'split' Thus I've changed the code as following. def to_cat_list(catstr): stripped=(x.strip() for x in str(catstr).split(',')) return [x for x



