显示谷歌排行榜的负值,从正面而不是右边

时间:2016-05-19 09:52:15

标签: javascript ruby-on-rails charts google-visualization chartkick

我使用%errorlevel% gem在我的rails应用中构建Google Charts。 但我在折线图中显示负值时遇到问题。负值在积极而不是之前。 enter image description here

我试图谷歌如何解决它,但没有找到任何解决方案。

代码示例:

chartkick

<%= line_chart([{name: 'name_1', data: @data_for_chart_1}, {name: 'name_2', data: @data_for_chart_2}], discrete: true, xtitle: "Cut Expenses By ($)", ytitle: "Max. Home Price ($)", colors: ["#2E3192", "red"], library: {title: "Cutting Expenses Makes Higher Priced Homes Affordable", curveType: "none", pointSize: 0, legend: { position: "bottom" }}, id: "chart" ) %> @data_for_chart_1是整数键和值。

0 个答案:

没有答案