test set python forecast report precision, recall, f1-score, support

from sklearn.metrics import confusion_matrix
from sklearn.metrics import classification_report

confusion_matrix(y_test, y_predict)

print(classification_report(y_test, y_predict))


           precision	recall	  f1-score	support
   A         0.9	  0.9	     0.9           23 
   B         0.84	  0.77       0.81	   51

microavg    xx	          xx	      xx	   74
macroavg    xx	          xx	      xx	   74
weightedavg xx	          xx	      xx	   74

 

Published 35 original articles · won praise 26 · views 80000 +

Guess you like

Origin blog.csdn.net/weixin_42342968/article/details/83617607