我正在尝试对每个指数进行3个最高的观察。例如,我有
{% extends "learning_logs/base.html" %}
{% block content %}
<a>Your quote has been deleted. Please click a link at the top of the
page to return.</a>
{% endblock content %}
我想对AL和AK进行3次最高观察,并将其作为其他系列进行观察。谢谢。
答案 0 :(得分:0)
您可以进行census.groupby(level=0).nlargest(3)
感谢@coldspeed