added logic and display for average rankings