added function to get average votings