pandas - calculating top 10 products for a given query based on its priority in python -
suppose given dataframe like: query productid priority index 0 3ds 2125233 0.018946 1 rca 2009324 0.027599 2 nook 1517163 0.009443 3 rca 2877125 0.012054 4 rca 2877134 0.005557 5 flatscreentvs 2416092 0.011961 6 macbook 3108172 0.010459 7 3ds 2264036 0.165948 8 rca 8280834 0.004006 9 memorycard 2740208 0.013744 10 acpowercord 2584273 0.006865 11 zaggiphone 1230537 0.136073 12 watchthethrone 3168067 0.104679 13 remotecontrolextender 7997055 0.113058 14 camcorder 2009041 0.017809 15 3ds 1988047 0.031711 16 3ds 1686079 0.043783 17 wirelessheadphones 3770439 0.014714 18 ...