1
mt = mobile.PattLen.value_counts() # sort True by default
我得到
4 2831
3 2555
5 1561
[...]
如果我做
mt = mobile.PattLen.value_counts(sort=False)
我得到
8 225
9 120
2 1234
[...]
我一個m試圖做的是以2,3,4升序(左數字列)獲得輸出。我可以改變value_counts或我需要使用不同的功能。