so i am trying to split a column in a DataFrame (df1) using the .str.split() function. column name is hyphenated (lat-lon). When i run the code below, python reads only the "lat" and ignores the "-lon" thereby returning
AttributeError: 'DataFrame' object has no attribute 'lat'
df1[['lat','lon']] = df1.lat-lon.str.split(" ",expand=True,)
df1
How do i get python to read the entire column name (lat-lon) and not just lat?