Is there a nicer way to check if pandas Series values are in pandas Interval:
import pandas as pd, numpy as np
x = pd.Series(np.linspace(4.0,7.8,num=20))
i = pd.Interval(5.0, 6.0, closed='left')
result = (i.left<=x) & (x<i.right)
Is it possible to compute result less explicitly, i.e. without accessing i.left, i.right, i.closed?
Something like x.isin(i) or x in i.
Thank you for your help!