[英]How can I labeled the X axis and Y axis in yellowbrick plot? The code is I used is show below
How can I labeled the X axis and Y axis in yellowbrick plot?如何在 yellowbrick plot 中标记 X 轴和 Y 轴? The code is I used is show below.
我使用的代码如下所示。
from yellowbrick.regressor import PredictionError
Visualizer = PredictionError(LL_dt)
Visualizer.fit(X_train,y_train)
Visualizer.score(X_test,y_test)
Visualizer.poof()
I tried adding我尝试添加
Visualizer.ax.set_xlabel("Measured")
Visualizer.ax.set_ylabel("Predicted")
but didn't work.但没有用。
Do not use "Visualizer.poof()".不要使用“Visualizer.poof()”。 add your xlabel and ylabel code right after score.
在得分后立即添加您的 xlabel 和 ylabel 代码。
Visualizer = PredictionError(LL_dt)
Visualizer.fit(X_train,y_train)
Visualizer.score(X_test,y_test)
Visualizer.ax.set_xlabel("Measured")
Visualizer.ax.set_ylabel("Predicted")
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.