Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 8

PREDICTING

CUSTOMER CHURN
LOGISTIC REGRESSION
ALGORITHM
Accuracy of algorithm: 0.804079696394687
Confusion matrix:

FALSE TRUE
0 1408 140
1 273 287
DECISION TREE ALGORITHM
Accuracy of algorithm: 0.764705882352941
Confusion matrix:

Predicted /Actual 0 1
No 1410 358
Yes 138 202
RANDOM FOREST
ALGORITHM
Type of random forest: classification (Before tuning)
Number of trees: 500
No of variables tried at each split: 4
OOB estimate of error rate: 20.59%
Confusion matrix:
No Yes Class.error
No 32504 3651 0.09986169
Yes 653 656 0.49885409
RANDOM FOREST
ALGORITHM
Type of random forest: classification (After tuning)
Number of trees: 200
No of variables tried at each split: 2
OOB estimate of error rate: 20.45%
Confusion matrix:
No Yes Class.error
No 3250 365 0.08713693
Yes 655 654 0.52864782
BAR DIAGRAM FROM
VARIABLE
CONCLUSION
Random Forest algorithm is one of the most widely used algorithms when it comes
to Machine Learning. R package randomForest is used to create large number of
decision trees and then each observation is inputted into the decision tree. The
common output obtained for maximum of the observations is considered as the final
output. When using randomForest algorithm, data scientists/analysts have to ensure
that the variables must be numeric or factors. Factors cannot have more than 32
levels when implementing random forest.
Thank You.

You might also like