16 Machine Learning Cheatsheet for R and Python

Jingyi Feng

The most popular languages for training machine learning models are R and Python (both have extensive packages and resources). For this community contribution, I build a cheat sheet for doing data pre-processing, machine learning, and simple data visualization in both R and Python. The structure of the cheat sheet is as follows:

  1. Data processing (import file, scaling, train test split)
  2. Supervised learning techniques (regression models, classification models)
  3. Unsupervised learning techniques (PCA, K-Means)
  4. Evaluating model performance (RMSE, R2, accuracy, confusion matrix, ROC-AUC, F1-score)
  5. Preliminary data visualization (ggplot2, seaborn)

The cheat sheet is available here: https://github.com/jenniferfjy/Community_Contribution/blob/main/MLCheatSheet.pdf