can you do dummy variables for these variables Player Name Pos CR Age G/A Dougla
ID: 3227153 • Letter: C
Question
can you do dummy variables for these variables
Player Name Pos CR Age G/A Douglas Costa OFF 2 24 0.195 André Schürrle OFF 1 24 0.288 Juan Cuadrado OFF 2 27 0.181 Mateo Kovai MID 1 21 0.087 Paulo Dybala OFF 2 21 0.297 Carlos Bacca OFF 2 28 0.539 Jackson Martínez OFF 2 28 0.642 Geoffrey Kondogbia MID 1 22 0.036 Morgan Schneiderlin MID 1 25 0.080 Arturo Vidal MID 1 28 0.287 Wilfried Bony OFF 1 26 0.597 Roberto Firmino OFF 1 23 0.271 Arda Turan MID 1 28 0.102 Christian Benteke OFF 1 24 0.496 Ángel Di María MID 1 27 0.166 Raheem Sterling MID 1 20 0.189 Kevin De Bruyne MID 1 24 0.255 Anthony Martial OFF 1 19 0.224 Robin van Persie OFF 1 31 0.631 Nani OFF 1 28 0.223 Bastian Schweinsteiger MID 1 30 0.184 Georginio Wijnaldum MID 2 24 0.378 Pedro OFF 1 27 0.204 Álvaro Negredo OFF 1 30 0.462 Son Heung-min OFF 1 23 0.306 Roberto Firmino OFF 2 23 0.271 Memphis Depay OFF 1 21 0.433 Antoine Griezmann OFF 1 22 0.257 Adam Lallana MID 2 26 0.243 Ander Herrera MID 1 24 0.070 Cesc Fàbregas MID 1 27 0.311 Diego Costa OFF 1 26 0.424 Alexis Sánchez OFF 1 26 0.371 Juan Mata MID 1 26 0.233 Ángel Di María OFF 1 26 0.180 James Rodríguez OFF 1 23 0.315 Luis Suárez OFF 1 27 0.694 Isco OFF 1 21 0.203 Henrikh Mkhitaryan OFF 1 21 0.459 Roberto Soldado OFF 1 28 0.547 Marouane Fellaini MID 1 25 0.181 Érik Lamela OFF 1 21 0.240 Willian MID 1 24 0.160 Mario Götze MID 1 21 0.282 Fernandinho MID 1 28 0.168 Gonzalo Higuaín OFF 1 25 0.664 Lucas Moura OFF 1 20 0.257 Mesut Özil MID 1 24 0.191 Radamel Falcao OFF 1 27 0.707 Edinson Cavani OFF 1 26 0.607 Neymar OFF 1 21 0.529 Gareth Bale OFF 1 24 0.290 Robin van Persie OFF 1 29 0.615 Ezequiel Lavezzi OFF 1 27 0.244 Oscar MID 1 20 0.234 Eden Hazard MID 1 21 0.252 Luka Modri MID 1 26 0.171 Axel Witsel MID 1 23 0.195 Hulk OFF 1 26 0.551 Juan Mata MID 1 22 0.256 Samir Nasri MID 1 24 0.178 Edin Džeko OFF 2 25 0.560 Andy Carroll OFF 2 22 0.418 Radamel Falcao OFF 2 25 0.527 Cesc Fàbregas OFF 1 24 0.208 Sergio Agüero OFF 2 23 0.423 Fernando Torres OFF 1 27 0.572 David Silva MID 1 24 0.163 James Milner MID 2 24 0.097 Yaya Touré MID 1 27 0.094 David Villa OFF 1 27 0.645 Emmanuel Adebayor OFF 1 25 0.371 Xabi Alonso MID 1 28 0.105 Karim Benzema OFF 1 22 0.439 Kaká MID 2 27 0.368 Zlatan Ibrahimovi OFF 1 27 0.506 Cristiano Ronaldo OFF 1 24 0.479Explanation / Answer
Dummy variables are mostly used for Regression analysis. It is nothing but an artificial variable created to replace the existing variable containing two or more level or categories of the data.
The analysis requires all the variables in the numerical form. But if some of the variables in data set are non numeric then we have to create a dummy variable for that non numeric variable to transform it into the numeric variable and make it useable for analysis.
In our example, the variable "pos" is with two categories of the position on the field. Thus, we can use dummy variable for the "pos" variable.
There are two categories of the position in the variable.
1. OFF
2. MID
So, if we give code "1" to OFF position and code "2" to MID position, the variable would only be in numbers 1 and 2.
Thus the variable "pos" will now be in the all numeric and can be used in the analysis.
So the data table with dummy variable would be
Player Name Pos Pos_Dummy CR Age G/A Douglas Costa OFF 1 2 24 0.195 André Schürrle OFF 1 1 24 0.288 Juan Cuadrado OFF 1 2 27 0.181 Mateo Kovai MID 2 1 21 0.087 Paulo Dybala OFF 1 2 21 0.297 Carlos Bacca OFF 1 2 28 0.539 Jackson Martínez OFF 1 2 28 0.642 Geoffrey Kondogbia MID 2 1 22 0.036 Morgan Schneiderlin MID 2 1 25 0.08 Arturo Vidal MID 2 1 28 0.287 Wilfried Bony OFF 1 1 26 0.597 Roberto Firmino OFF 1 1 23 0.271 Arda Turan MID 2 1 28 0.102 Christian Benteke OFF 1 1 24 0.496 Ángel Di María MID 2 1 27 0.166 Raheem Sterling MID 2 1 20 0.189 Kevin De Bruyne MID 2 1 24 0.255 Anthony Martial OFF 1 1 19 0.224 Robin van Persie OFF 1 1 31 0.631 Nani OFF 1 1 28 0.223 Bastian Schweinsteiger MID 2 1 30 0.184 Georginio Wijnaldum MID 2 2 24 0.378 Pedro OFF 1 1 27 0.204 Álvaro Negredo OFF 1 1 30 0.462 Son Heung-min OFF 1 1 23 0.306 Roberto Firmino OFF 1 2 23 0.271 Memphis Depay OFF 1 1 21 0.433 Antoine Griezmann OFF 1 1 22 0.257 Adam Lallana MID 2 2 26 0.243 Ander Herrera MID 2 1 24 0.07 Cesc Fàbregas MID 2 1 27 0.311 Diego Costa OFF 1 1 26 0.424 Alexis Sánchez OFF 1 1 26 0.371 Juan Mata MID 2 1 26 0.233 Ángel Di María OFF 1 1 26 0.18 James Rodríguez OFF 1 1 23 0.315 Luis Suárez OFF 1 1 27 0.694 Isco OFF 1 1 21 0.203 Henrikh Mkhitaryan OFF 1 1 21 0.459 Roberto Soldado OFF 1 1 28 0.547 Marouane Fellaini MID 2 1 25 0.181 Érik Lamela OFF 1 1 21 0.24 Willian MID 2 1 24 0.16 Mario Götze MID 2 1 21 0.282 Fernandinho MID 2 1 28 0.168 Gonzalo Higuaín OFF 1 1 25 0.664 Lucas Moura OFF 1 1 20 0.257 Mesut Özil MID 2 1 24 0.191 Radamel Falcao OFF 1 1 27 0.707 Edinson Cavani OFF 1 1 26 0.607 Neymar OFF 1 1 21 0.529 Gareth Bale OFF 1 1 24 0.29 Robin van Persie OFF 1 1 29 0.615 Ezequiel Lavezzi OFF 1 1 27 0.244 Oscar MID 2 1 20 0.234 Eden Hazard MID 2 1 21 0.252 Luka Modri MID 2 1 26 0.171 Axel Witsel MID 2 1 23 0.195 Hulk OFF 1 1 26 0.551 Juan Mata MID 2 1 22 0.256 Samir Nasri MID 2 1 24 0.178 Edin Džeko OFF 1 2 25 0.56 Andy Carroll OFF 1 2 22 0.418 Radamel Falcao OFF 1 2 25 0.527 Cesc Fàbregas OFF 1 1 24 0.208 Sergio Agüero OFF 1 2 23 0.423 Fernando Torres OFF 1 1 27 0.572 David Silva MID 2 1 24 0.163 James Milner MID 2 2 24 0.097 Yaya Touré MID 2 1 27 0.094 David Villa OFF 1 1 27 0.645 Emmanuel Adebayor OFF 1 1 25 0.371 Xabi Alonso MID 2 1 28 0.105 Karim Benzema OFF 1 1 22 0.439 Kaká MID 2 2 27 0.368 Zlatan Ibrahimovi OFF 1 1 27 0.506 Cristiano Ronaldo OFF 1 1 24 0.479Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.