overlaying Parent: layout.xaxis Type: enumerated , one of ( "free" |
"/^x([2-9]|[1-9][0-9]+)?$/" | "/^y([2-9]|[1-9][0-9]+)?$/" ) If set a
same-letter axis id, this axis is overlaid on top of the corresponding
same-letter axis, with traces and axes visible for both axes. If
"False", this axis does not overlay any same-letter axes. In this
case, for axes with overlapping domains only the highest-numbered axis
will be visible.
回答:
次y轴上的轨迹将显示在顶部。不管它是
go.Scatter()
跟踪还是go.Bar()
跟踪详细信息:
overlaying
属性仅适用于具有两个以上y轴的情况,如here:从the docs可以看到:
那么,你的案子呢? 通常,记录道按其添加到
fig
的顺序显示。但对于具有两个y轴的图形,情况并非如此。看起来您必须切换显示在主轴上的轨迹。第一个代码段生成一个在主轴上带有条形的图形。第二个代码段生成了一个在次轴上带有条形的图形。这也决定了哪个轨迹显示在顶部代码1:
图2(图3)
图1:
代码2:
图2:
相关问题 更多 >
编程相关推荐