# Create a dictionary to map timezone abbreviations to their corresponding UTC offsets.
timezone_map = {
'CST': '-0600'
}
# Replace the timezone abbreviation in the string with its corresponding UTC offset
for abbreviation, offset in timezone_map.items():
ts = ts.replace(abbreviation, offset)
# Convert the modified time string to a datetime object
datetime_object = pd.to_datetime(ts)
print(datetime_object)
您将需要
pd.to_datetime()
功能来实现您的要求。就像是:演示在这里