Python 如何在';右下角';

Python 如何在';右下角';,python,bokeh,roc,Python,Bokeh,Roc,我正在尝试使用Bokeh生成ROC曲线。我有以下以前运行过的代码,但现在我得到一个错误:ValueError:invalid value:'bottom_right';允许的值为水平或垂直 p = figure(title='ROC Curve: Logistic Regression', width=800, height=800) p.line(x=fpr, y=tpr, legend='ROC Curve: Area Under Curve = %0.3f' %roc_auc) p.le

我正在尝试使用Bokeh生成ROC曲线。我有以下以前运行过的代码,但现在我得到一个错误:ValueError:invalid value:'bottom_right';允许的值为水平或垂直

p = figure(title='ROC Curve: Logistic Regression', width=800, height=800)

p.line(x=fpr, y=tpr, legend='ROC Curve: Area Under Curve = %0.3f' %roc_auc)
p.legend.orientation = 'bottom_right'
p.xaxis.axis_label = 'False Positive Rate'
p.yaxis.axis_label = 'True Positive Rate'
show(p)

我想做的就是把图例放在屏幕底部,这样它就不会覆盖部分曲线。有人能给我建议吗?谢谢。

您想设置
位置
,而不是
方向

p.legend.location = 'bottom_right'