-
- Notifications
You must be signed in to change notification settings - Fork 19.4k
Closed
Labels
Error ReportingIncorrect or improved errors from pandasIncorrect or improved errors from pandasReshapingConcat, Merge/Join, Stack/Unstack, ExplodeConcat, Merge/Join, Stack/Unstack, Explode
Milestone
Description
merge_asof arguments have to "...be a numeric column, such as datetimelike, integer, or float" but gives cryptic TypeError instead of ValueError on bad argument types?
import pandas as pd left = pd.Series(['2019-06-01 00:09:12', '2019-06-01 00:10:29', '2019-06-01 00:20:30'], name='time') right = pd.Series(['2019-06-01 00:01:12', '2019-06-01 00:01:12', '2019-06-01 00:01:12'], name='time') pd.merge_asof(left, right)Output:
... TypeError: No matching signature found versus e.g.
import pandas as pd left = pd.Series(['2019-06-01 00:09:12', '2019-06-01 00:10:29', '2019-06-01 00:20:30'], name='time') right = pd.Series(['2019-06-01 00:01:12', '2019-06-01 00:01:12', '2019-06-01 00:01:12'], name='time') left = pd.to_datetime(left, infer_datetime_format=True) right = pd.to_datetime(right, infer_datetime_format=True) pd.merge_asof(left, right)Metadata
Metadata
Assignees
Labels
Error ReportingIncorrect or improved errors from pandasIncorrect or improved errors from pandasReshapingConcat, Merge/Join, Stack/Unstack, ExplodeConcat, Merge/Join, Stack/Unstack, Explode