MCPcopy Index your code
hub / github.com/lazyprogrammer/machine_learning_examples / score

Method score

bayesian_ml/1/nb.py:75–76  ·  view source on GitHub ↗
(self, X, Y)

Source from the content-addressed store, hash-verified

73 return np.round(self.predict_proba(X))
74
75 def score(self, X, Y):
76 return np.mean(self.predict(X) == Y)
77
78 def confusion_matrix(self, X, Y):
79 P = self.predict(X)

Callers 1

nb.pyFile · 0.45

Calls 1

predictMethod · 0.95

Tested by

no test coverage detected