My test set data contains about 50,000 instances. I trained different machine learning models. Now I want to do some comparison to see for example if for every instance x_i
that model A predicted as 0, models B and C also predicted that instance as 0.
For example, below are the first 5 predictions by the models.
import pandas as pd
data = {'true_class': [3.0, 3.0, 3.0, 3.0, 3.0],
'rf_pred': [3.0, 0.0, 0.0, 0.0, 0.0],
'mlp_pred': [3.0, 0.0, 0.0, 0.0, 0.0],
'knn_pred': [3.0, 0.0, 0.0, 0.0, 0.0],
'lg_pred': [3.0, 0.0, 0.0, 0.0, 0.0],
'ada_pred': [2.0, 2.0, 2.0, 2.0, 2.0]}
df = pd.DataFrame(data)
df
true_class rf_pred mlp_pred knn_pred lg_pred ada_pred
0 3.0 3.0 3.0 3.0 3.0 2.0
1 3.0 0.0 0.0 0.0 0.0 2.0
2 3.0 0.0 0.0 0.0 0.0 2.0
3 3.0 0.0 0.0 0.0 0.0 2.0
4 3.0 0.0 0.0 0.0 0.0 2.0
Clearly predictions of rf_pred, mlp_pred, knn_pred
& lg_pred
are the same for these five instances.
Is there any way to perform such analysis, per haps visually?