Tried with different parameters - Max score 82

Hi ,

I have tried training with different parameters but the max score im able to achieve is 82%.

Please see my training code below:

param_grid = { “criterion” : [“entropy”], “min_samples_leaf” : [1, 5, 10, 15, 20], “min_samples_split” : [2, 4, 7,10, 12, 16, 18, 25, 35], “n_estimators”: [5,10,15,20,25,30]}
from sklearn.model_selection import GridSearchCV, cross_val_score
rf = RandomForestClassifier(n_estimators=10, max_features=‘auto’)
clf = GridSearchCV(estimator=rf, param_grid=param_grid)
clf.fit(X, Y)

clf.best_params_

Then taking the best parameters to train the model and using that model for predictions

random_forest = RandomForestClassifier(criterion = “entropy”,
min_samples_leaf = 1,
min_samples_split = 12,
n_estimators=20,
max_features=‘auto’)

random_forest.fit(X, Y)
Y_prediction = random_forest.predict(X_test)

random_forest.score(X, Y)

YPredForest = random_forest.predict(X_test)

hey @lintasheelkumar ,
I see that you have gone in lot of depth with parameters using RandomForest model.
And its really good.

Now to further increase accuracy what you can do is ,

  1. Feature engineering
  2. Tuning ( Already did )
  3. Changing the model , a more advanced might be helpful
  4. Standardizing or normalizing the data.
  5. Ensembling multiple models.

Try them ,if you don’t know about anyone , search a bit and if still you don’t understand then i can help you out.

Happy Learning :slightly_smiling_face:.

Thank you for the explanation.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.