你好,
我正在尝试创建一个带有 2 y 轴的条形图。 但每当我将一列向右移动以创建第二个轴时,条形几乎是嵌套的,我无法将它们分开。


我希望条形像第一张图中那样是分开的,但有两个不同的轴。
似乎是我缺少的一些非常基本的东西 - 它是什么?
谢谢,
埃兰
谢谢,
我了解具有不同 y 尺度的图表的潜在问题,但显示数据的方向很有帮助,而且我不确定将信息放在不同的图表上总是更好。
感谢您提供的解决方案 - 它确实完美地解决了这个问题。
最好的,
埃兰
你好@eranse ,
我猜你想要第二个轴,因为第 3 列的大小比第 2 列和第 4 列大得多。 然而,在我看来,两轴条形图充满了误解的风险:值为 90 的条形图与高度大致相同且值为 340 的条形图相邻,令人感到不和谐。我认为两个轴图对于用线条显示数据趋势很有用,即使如此,前提是轴的颜色与曲线相匹配等。
由于 GraphBuilder 平台无法生成您需要的内容,我建议使用替代图

Graph Builder(
Size( 763, 517 ),
Show Control Panel( 0 ),
Graph Spacing( 10 ),
Variables( X( :Column 1 ), Y( :Column 4 ), Y( :Column 2 ), Y( :Column 3 ) ),
Elements(
Position( 1, 1 ),
Bar( X, Y, Legend( 9 ), Label( "Label by Value" ) )
),
Elements(
Position( 1, 2 ),
Bar( X, Y, Legend( 8 ), Label( "Label by Value" ) )
),
Elements(
Position( 1, 3 ),
Bar( X, Y, Legend( 7 ), Label( "Label by Value" ) )
),
SendToReport(
Dispatch( {}, "Graph Builder", OutlineBox, {Select} ),
Dispatch( {}, "Column 4", ScaleBox, {Label Row( Show Major Grid( 1 ) )} ),
Dispatch( {}, "Column 2", ScaleBox, {Label Row( Show Major Grid( 1 ) )} ),
Dispatch( {}, "Column 3", ScaleBox, {Label Row( Show Major Grid( 1 ) )} ),
Dispatch(
{},
"Y title",
TextEditBox,
{Set Font Size( 12 ), Set Font Style( "Bold" ), Font Color( 53 )}
),
Dispatch(
{},
"Y 1 title",
TextEditBox,
{Set Font Size( 12 ), Set Font Style( "Bold" ), Font Color( 19 )}
),
Dispatch(
{},
"Y 2 title",
TextEditBox,
{Set Font Size( 12 ), Set Font Style( "Bold" ), Font Color( 20 )}
),
Dispatch(
{},
"400",
LegendBox,
{Legend Position( {9, [1], 8, [0], 7, [2]} ), Position( {1, 0, 2} )}
)
)
)
但是,我可以创建您想要的图表(我不喜欢)。 它需要重组您的数据。 请参阅随附的创建数据表和该图的日志。

“仅仅因为你可以,并不意味着你应该这样做。”