MACHINE LEARNING

APPLICATION OF SUPERVISED LEARNING

MACHINE LEARNINGHARD QUESTIONS

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
what is the function of the following code? y ____ pred = pipe.predict(X ____ test) r2 ____ score(y ____ test, y ____ pred)
A
Predicting and calculating the accuracy of the training model
B
Return the size training set
C
Return the size of the testing set
D
Predicting for test values and calculating the score of prediction
Explanation: 

Detailed explanation-1: -The Sklearn ‘Predict’ Method Predicts an Output Scikit learn is a machine learning toolkit for Python. That being the case, it provides a set of tools for doing things like training and evaluating machine learning models.

Detailed explanation-2: -The R2 score is a very important metric that is used to evaluate the performance of a regression-based machine learning model. It is pronounced as R squared and is also known as the coefficient of determination. It works by measuring the amount of variance in the predictions explained by the dataset.

Detailed explanation-3: -Think of score as a shorthand to calculate accuracy since it is such a common metric. It is also implemented to avoid calculating accuracy like this which involves more steps: from sklearn.metrics import accuracy score preds = clf.predict(X test) accuracy score(y test, preds)

There is 1 question to complete.