Cargar datos

games <- read.csv("IGN_games_from_best_to_worst.csv")
head(games) %>%
  kable() %>%
  kable_styling(bootstrap_options = c("striped", "hover"))
title score score_phrase platform genre release_year release_month release_day
Checkered Flag 10 Masterpiece Lynx Racing 1999 7 6
Chrono Trigger 10 Masterpiece Wii Action, RPG 2011 5 25
Dragon Warrior III 10 Masterpiece Game Boy Color RPG 2001 7 20
Grand Theft Auto IV 10 Masterpiece Xbox 360 Action, Adventure 2008 4 25
Grand Theft Auto IV 10 Masterpiece PlayStation 3 Action, Adventure 2008 4 25
Grand Theft Auto IV (Special Edition) 10 Masterpiece Xbox 360 Action 2008 4 29

Variable cualitativa 1: score_phrase

tabla1 <- table(games$score_phrase)
kable(tabla1, col.names = c("Calificación", "Frecuencia")) %>%
  kable_styling(bootstrap_options = c("striped", "hover"), full_width = FALSE)
Calificación Frecuencia
Amazing 1804
Awful 664
Bad 1269
Disaster 3
Good 4741
Great 4773
Masterpiece 55
Mediocre 1959
Okay 2945
Painful 340
Unbearable 72
kable(round(prop.table(tabla1) * 100, 1), col.names = c("Calificación", "Porcentaje")) %>%
  kable_styling(bootstrap_options = c("striped", "hover"), full_width = FALSE)
Calificación Porcentaje
Amazing 9.7
Awful 3.6
Bad 6.8
Disaster 0.0
Good 25.5
Great 25.6
Masterpiece 0.3
Mediocre 10.5
Okay 15.8
Painful 1.8
Unbearable 0.4

Variable cualitativa 2: platform (top 10)

tabla2 <- sort(table(games$platform), decreasing = TRUE)[1:10]
kable(tabla2, col.names = c("Plataforma", "Frecuencia")) %>%
  kable_styling(bootstrap_options = c("striped", "hover"), full_width = FALSE)
Plataforma Frecuencia
PC 3370
PlayStation 2 1686
Xbox 360 1631
Wii 1366
PlayStation 3 1356
Nintendo DS 1045
PlayStation 952
Wireless 910
iPhone 842
Xbox 821
kable(round(prop.table(tabla2) * 100, 1), col.names = c("Plataforma", "Porcentaje")) %>%
  kable_styling(bootstrap_options = c("striped", "hover"), full_width = FALSE)
Plataforma Porcentaje
PC 24.1
PlayStation 2 12.1
Xbox 360 11.7
Wii 9.8
PlayStation 3 9.7
Nintendo DS 7.5
PlayStation 6.8
Wireless 6.5
iPhone 6.0
Xbox 5.9

Variable cuantitativa 1: score

kable(t(as.matrix(summary(games$score)))) %>%
  kable_styling(bootstrap_options = c("striped", "hover"), full_width = FALSE)
Min. 1st Qu. Median Mean 3rd Qu. Max.
0.5 6 7.3 6.950459 8.2 10

Desviación estándar: 1.71

Variable cuantitativa 2: release_year

kable(t(as.matrix(summary(games$release_year)))) %>%
  kable_styling(bootstrap_options = c("striped", "hover"), full_width = FALSE)
Min. 1st Qu. Median Mean 3rd Qu. Max.
1970 2003 2007 2006.515 2010 2016

Desviación estándar: 4.59