"How do i plot the score acquired by each player?"
First add this to User:
has_many :levels, :through => :games
Then get the total score per player with:
User.includes(:levels).group(:email).sum(:score)
"And then the average score acquired by each player each game?"
User.includes(:levels).group(:email, :game_id).average(:score)
This returns a hash with a tuple (email, game_id) as key and the average as value. Grouping by email is only to be able to get some user identification back in the results but there should be a nicer way to do it somehow.