📜  scikit learn r2 score - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:16.250000             🧑  作者: Mango

代码示例2
from sklearn.metrics import r2_score
y_true = [3, -0.5, 2, 7]
y_pred = [2.5, 0.0, 2, 8]
r2_score(y_true, y_pred)