Added function to get user stats

close issue 3