Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/multithreading/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 有没有办法改变散点图上的原点轴(零线)?_Python_Plotly_Plotly Python - Fatal编程技术网

Python 有没有办法改变散点图上的原点轴(零线)?

Python 有没有办法改变散点图上的原点轴(零线)?,python,plotly,plotly-python,Python,Plotly,Plotly Python,有没有办法改变散点图上的轴?假设将轴从(0,0)即(零线)移动到类似(3,3)的位置,并制作一个象限图 我已经尝试将“xaxis”和“yaxis”上的“zeroline”值设置为False,然后从“shapes”在两个轴上绘制两条常量线。 但我想知道是否有办法改变原点轴 如果运行help(图['layout']['xaxis'])您将看到zeroline的唯一选项是: zeroline Determines whether or not a line is drawn at alo

有没有办法改变散点图上的轴?假设将轴从(0,0)即(零线)移动到类似(3,3)的位置,并制作一个象限图

我已经尝试将“xaxis”和“yaxis”上的“zeroline”值设置为False,然后从“shapes”在两个轴上绘制两条常量线。 但我想知道是否有办法改变原点轴

如果运行
help(图['layout']['xaxis'])
您将看到
zeroline
的唯一选项是:

 zeroline
     Determines whether or not a line is drawn at along the
     0 value of this axis. If True, the zero line is drawn
     on top of the grid lines.
 zerolinecolor
     Sets the line color of the zero line.
 zerolinewidth
     Sets the width (in px) of the zero line.
所以如果你的方法是

将“xaxis”和“yaxis”上的“零线”值设置为False,然后 然后从“形状”沿两个轴绘制两条恒定线


…对你来说是可行的,我真的认为这是你最好的选择。

关于@vestland上面提到的“两条常数线”的例子;你也许愿意。
 zeroline
     Determines whether or not a line is drawn at along the
     0 value of this axis. If True, the zero line is drawn
     on top of the grid lines.
 zerolinecolor
     Sets the line color of the zero line.
 zerolinewidth
     Sets the width (in px) of the zero line.