1
$\begingroup$

I'd like to make a model to predict the result of a match in a video game (win or loss).

The game is 3 players against 3 players, and each player has a specific character with specific characteristics, abilities, etc.

There are around 15 different characters.

My problem is that I don't know how to model that kind of data because it's non-numeric data, and, for example, Scikit-Learn doesn't handle categorical variables.

I read a lot about how to handle that, but couldn't find an approach which seems to be the good one for my case.

I can't really find a numeric value which could be representative and replace the character name variable. Do you have an idea of how I should do that, or maybe just a way to find out?

$\endgroup$

1 Answer 1

0
$\begingroup$

If the only possible results are win/lose, then you are in front of a binary classification problem (so SVM, trees, logistic regression and all of the others can apply). I don't know about scikit-learn in particular, but most machine learning packages will create the dummy variables for you (you only have to provide them with a column containing the labels, and the software will do the job)

The idea behind these dummy variables is to separate a categorical variable with $n$ groups into $n$ different binary variables (if the individual in question belongs to the $k$th category, then the $k$th dummy variable will be $1$ and the rest will take the value $0$)

In practice, what is most commonly done is take a "reference group" (normally, the majority group) and $(n-1)$ dummy variables. If all dummy variables are $0$, the individual belongs to the reference group. Otherwise, it belongs to the corresponding alternative category

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.