script to search max rx tx in torch and get ip

Hello! I need help. Need a script that would look for the maximum values ​​of tx and rx in torch tool and get me ip-address with max tx and rx value.

I think the interface torch is a interactive tool and cant be scripted.

Maybe you can use traffic accounting.