BUILDING FIRST PREDICTIVE MODEL


 Steps to make First base model

1. Create the Data set for predictive model :-

it is basically the first step of the predictive model assume entire data which is Available is in the form of the boxes of x and y the box of x is greater than the box of the y
y  = dependent variable
x = independent variable
we are essentially trying to do in this predictive model is to find the maping which takes x as the input and gives us y as the output and we want to do this for all my future use causes for example we have all the parsed data of default in cause of the bank and we use to create the relationship  so we can say that the person not pay us the money back in this particular time and more than the given amount the chances of the person having default are very high hair the main challenge is how to create the predictive model of our data we divide our given data in the two part the first part is called as the training data set and the second part are the testing data set we do this in order to make shore our model is robust ad not over fit the data
the train data is actually use to build the model and we use the test data to check that the prediction we are getting through our model is right or not we need to do this because we don't have enough data to test this model
we divide our data randomly or in cause of time dependent variable we move the current day to one of the day in past and assume the data are in hypothetical current day and the current day is actually my
future data

2. Methods to generate predictions:-

The Modeling process id iterative in nature we can't build a model in our first shot so we need to build a model and continuously improve the model first we need to generate our hypothesis later we need to build the data set with the help our hypothesis later on we need to build the model with the help of the data set and when our model is build we evaluate our model and improve it continuously using the better set of hypothesis and model technique

Problem Types - Supervised Machine Learning

1. regression:-    the problem in which we are predicting something continuous i.e big mart sales  

Big mart sales

To Build a predictive model and find out the sales of each product at the particular store
lets predict a sales price of a cheese price sell on the different store
first we need to build down the hypothesis that how we can predict the price
first step is to consider the mean of the price of butter at the different store and we can predict the price of the butter but this model is to simple we need to evaluate it using the the relation between the price of  the mean of the butter and other independent  variable  and we can also add more independent variable to make our model more effective
once we build this model we need to evaluate it by using
Mean Absolute Error:-  Sum of absolute difference between every observation, divided by the number of observations
in evaluation we will go and check how difference between the actual price and the predictive price we need to evaluate and build the better hypothesis to make this difference as lowest as possible
              
2.Classification:- the problem in which we need to divide our outcomes in several  classes for example:- a person survive the titanic tragedy or not

2. classification problem:- the problem where we need to classify the outcomes in the several classes

Solution on Jupyter Notebook:- https://github.com/deepak6210/Machine-learning/blob/master/regression(ML).py

Titanic survival prediction

here we need to predict the particular person survive the titanic incidence or not
outcomes of this problem is the zero,one zero stands for no survival and 1 stands for yes the person is survived
we can't used mean to predict the classification problem
so we need to create a simple bench mark model
* the mode of survival
* gender based survival
* other combination
we can do lots of thing but the main thing is we need to use mode insist of mean the classification problem
Accuracy:- correctly prediction observation upon total observations
first we build our model than  we need to evaluate it using the evaluation matrices
and check it accuracy

Comments

Popular Posts