'Python: How to find nth minimum value from a dataframe column?

Have got a dataframe like below:

Store       Row_no
11          56
11          57
11          58
12          89
12          90
12          91
12          92

For each store need to get 3rd minimum value from Row_no. Expected output below.

Store       Row_no
11          58
12          91

have tried df.Row_no.nsmallest(3) but it works different. Any help will be appreciated. Thank You!



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source