我需要在Pandas索引中找到标签的整数位置.我知道我可以使用get_loc方法,但后来我发现了searchsorted.只是想知道我是否应该使用后者来提高速度,因为我需要搜索数以千计的标签.
python pandas
pandas ×1
python ×1