Try   HackMD

Types of Machine learning

  • Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →
  • Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →
  • Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →
  • Image Not Showing Possible Reasons
    • The image was uploaded to a note which you don't have access to
    • The note which the image was originally uploaded to has been deleted
    Learn More →

Supervised (input -> output)

Regression (output is continuous)

  • Linear Regression
  • Support Vector Machine (Support Vector Regression)
  • K Nearest Neighbours
  • Decision Tree
  • Random Forest

Classification (output is discrete)

  • Logistic Regression
  • Naïve Bayes
  • Support Vector Machine (Support Vector Classification)
  • K Nearest Neighbours
  • Decision Tree
  • Random Forest

Unsupervised (learns patterns and structures from unlabeled data)

Clustering

  • K-Means
    • Identify groups of data points that are similar to each other within the same cluster while being different from data points in other clusters.

Dimension reduction

  • Principal Component Analysis (PCA)
    • Find the best way to tell a story using just a few important pictures, instead of showing every single detail and tons of words.

Reinforcement (teaching a robot/dog to play a game: it learns by trying different things, getting rewards when it does well, and figuring out how to do better next time.)

Watch this video to review Supervised and Unsupervised models.

Steps of Machine learning

  • Data Collection
  • Data Preparation (preprocessing)
    • Handling missing values and data formats
      • Image Not Showing Possible Reasons
        • The image was uploaded to a note which you don't have access to
        • The note which the image was originally uploaded to has been deleted
        Learn More →
      • Country name: Germany, GERMANY, germany, Deutschland, DE, De, de
      • True/false: TRUE, true, True, FALSE, False, false, 1, 0
    • Feature selection
    • Dimensionality reduction
    • Normalization
  • Choice of Model
  • Training of Model
    • Remember to split the data into the training set and testing set
  • Evaluation of Model
  • Parameter Tuning and Optimization
  • Predictions and Deployment

Common Libraries

Ways of importing libraries

# 1. from sklearn.linear_model import LinearRegression model = LinearRegression() # 2. from sklearn import linear_model model = linear_model.LinearRegression() # 3. import sklearn model = sklearn.linear_model.LinearRegression()
# 1. from sklearn.datasets import load_breast_cancer from sklearn.model_selection import train_test_split, cross_val_score from sklearn.svm import SVC # 2. from sklearn.datasets import load_breast_cancer from sklearn.model_selection import train_test_split from sklearn.model_selection import cross_val_score from sklearn.svm import SVC # 3. import sklearn dataset = sklearn.datasets.load_breast_cancer() train_test_split = sklearn.model_selection.train_test_split() cross_val_score = sklearn.model_selection.cross_val_score() SVC = sklearn.svm.SVC()