library(dplyr) library(readr)
##Introduction
This assignment extends Project 1 by applying the Elo rating formula to the chess tournament data. Using player pre-ratings and the average pre-rating of opponents, expected scores are calculated and compared to actual tournament results to identify overperforming and underperforming players.
##Load Project 1 Data
chess <- read_csv(“https://YOUR_PROJECT1_CSV_LINK_HERE.csv”)
##Elo Expected Score Formula chess <- chess %>% mutate( expected_score = 7 * (1 / (1 + 10 ^ ((avg_opponent_pre_rating - player_pre_rating) / 400))) )
##Difference Between Actual and Expected Score
chess <- chess %>% mutate(score_difference = total_points - expected_score) ##Top 5 Overperforming Players chess %>% arrange(desc(score_difference)) %>% select(player_name, total_points, expected_score, score_difference) %>% head(5) ##Top 5 Underperforming Players chess %>% arrange(score_difference) %>% select(player_name, total_points, expected_score, score_difference) %>% head(5)
##Conclusions
The results show that some players significantly outperformed their Elo-based expectations, while others underperformed. Using expected score calculations provides a clearer evaluation of player performance than raw point totals alone.