Member-only story
Data Project — Pokemon Battle Prediction (2): Predict with Machine Learning
Based on the data exploration in the last post, applying ML to the processed data is not very difficult. This is because there are mature python libraries that provide built models. We can import those models and use processed data to train/fit the model. Three well-known libraries are Pytorch, TensorFlow and Scikit-learn. I use Scikit-learn, which is the easiest one for this project. I’d like to explore the differences among those libraries and write another post about it in the future.
The Jupyter Notebook is here: https://github.com/reneelin1712/data-projects/tree/main/pokemon
1. A brief introduction to Machine Learning and Supervised learning
According to the correlation analysis in the last post, we know speed and attack are two major features that influence the battle results. Before Machine Learning, we might try to construct a linear function to express the relationships. For example: win_percentage = 0.4*speed + 0.6*attack. We tried to adjust the parameters manually based on the data we had.