Aug-21-2019, 04:56 PM
If you would have looked here you´d seen that you need to provide a dictionary and not a list of column names.
df.astype({'theyear':'int64', 'themonth':'int64'}, copy=False)