6.4. cpforager.utils.convert_loc_to_utc
- cpforager.utils.convert_loc_to_utc(df, local_timezone)
Convert
datetimecolumn from the local timezone to UTC.- Parameters:
df (pandas.DataFrame) – dataframe with a
datetimecolumn at the local timezone.local_timezone (str) – local timezone following the pytz nomenclature (see
pytz.all_timezones).
- Returns:
the dataframe with a
datetimecolumn to UTC timezone.- Return type:
pandas.DataFrame