As the error states, you can only use .str
with string columns, and you have a float64
. There won't be any commas in a float, so what you have won't really do anything, but in general, you could cast it first:
dc_listings['price'].astype(str).str.replace...
from : https://stackoverflow.com/questions/52065909/attributeerror-can-only-use-str-accessor-with-string-values-which-use-np-obje
No comments:
Post a Comment