I have a data frame trying to get the most common hour of day from a column
df[\'time\'] = pd.to_datetime(df[\'time\']) df[\'hour\'] = df[\'time\'].dt.hour