After the gathering, cleaning, and preprocessing of data to understand and recover insight from it, one way of implementing these is through the development of machine learning models.
Machine learning can be said to be a subfield in the data science field as well as in AI(artificial intelligence), as the name implies a computer can learn and make predictions based on what its data learned. This is important as it has led to the creation of important models like weather forecasts, fraud detection, and so on.
There are three types of machine learning
- Supervised machine learning
- Unsupervised machine learning
- Reinforcement machine learning
Supervised machine learning: This is the type of machine learning whereby it has a target value. This consists of data used to make the prediction (independent variables) and a target value to be predicted (dependent variables).
There are two types of supervised machine learning:
- Regression
- Classification
Regression: Regression is the aspect of supervised machine learning that deals with the prediction of quantitative or numerical data. In this type of supervised machine learning, all values are numeric and it plots them(the features of the data to be used) on a graph and then draws a line over them, this line can be called the line of best fit. This prediction algorithm can be in the form y=mx+c (equation of a line) where x is the feature(provided only one feature was used for the prediction), and m and c are constants obtained from the findings of the computer. For example, y=26x+7 takes the feature value in new data x=15 and then uses the formula to apply it y=26*15+7, y=397
When the number of features is increased it can be written as y=c+mx, mx2, mx3...
This can be used when predicting house price values or other numerical operations. A model that does this is Sk-learn's Linear Regression model.
Classification: Unlike regression, the classification uses qualitative values as target values. The data consists of values that are numerical or boolean while the target values are the classified value names to be predicted, each feature is evaluated and separated by some complex algorithm by the computer so when it evaluates each of the features of the test data it will fit it into one of the categories listed. This is done in various real-life scenarios like a fraud detection model or an image classification model. There are several models for classification like a Decision tree classifier, logistic regression(it says regression but it is used to build classification models), K neighbors classifier, Random forest classifier, and so on.
Unsupervised machine learning: This is a type of machine learning algorithm where there is no target value, but the computer, finding matches between them, classifies or groups the data in clusters based on their values. As mentioned above there is no target value but the aim of the computer is to find a connection between each value, this is used in algorithms like movie recommendation systems, based on the movies and get as you watch you might like. This modelling technique is called clustering. One of Sk-learn's clustering algorithms is KMeans clustering.
Reinforcement machine learning: this is an aspect of machine learning where the computer learns to interact with the environment, examples of these are games like chess, in which the computer doesn't know the game but learns how to play it with time according to the rules of the game, another example is self-driving cars which have motion sensors in them which help the computer learn how to move under certain scenarios.
The four main steps or lines in a model building in machine learning after the visualisation and preprocessing are:
- Separate the processed data into the train set and test set.
- Load or import the model to be used.
- Use the training set to train the model.
- Evaluate the model using the appropriate method with the test set.
From simple modelling like the prediction of house pricing to complex ones like image recognition, machine learning has automated a lot of tasks and improved Information Technology in a lot of ways.
Thanks for reading this article, like, share, and comment on what you think thanks.
Top comments (0)