# Which ML method would be best for deriving a rough formula for prediction based on existing data?

Which ML method would you say is the easiest to derive a mathematical formula from based on already existing data of predictor stats and outcome?

I have this data:

Opponent 1:

• Strength: x
• Battle Score: y

I also have a model that I put against the opponent:

Opponent 2:

• Strength: z
• Battle Score: k

Finally, all outcomes of fights are written into a database (which currently has around 2800 outcomes) and look something like this model:

Fight:

• Strength: x - z
• Battle Score: y - k
• Outcome: win/lose

I would want to get proper weights for Strength and Battle Score, so I can derive a simple formula from it and thus somewhat predict whether the next fight will be won or lost.

• Linear regression will do the job here – Aditya Oct 6 '18 at 11:17

If you want "the easiest" for "a simple formula", then for sure it will be a linear regression on the battle score, or a logistic regression on "win/lose". That way you'll have the coefficients of the model, and they will be interpretable (which you won't get from a neural network with hundreds of parameters).

You have to do binary classification. Here is how in Keras:

1. Organize your dataset so that it looks like a matrix or a pandas dataframe: 1. Outcome is going to be the label vector and the matrix without fight id and Outcome is going to be the features of the dataset.

2. Divide the dataset in train and test, for example with scikit learn train_test_split

3. Build a simple model with Keras

model = Sequential()

model.fit(train_x, train_y, epochs= 2, batch_size = 500, validation_data = (test_x, test_y))