Building out stats page functionality