打开APP
userphoto
未登录

开通VIP,畅享免费电子书等14项超值服

开通VIP
Plotting the secondary y-axis on the left side of the chart.
http://jsfiddle.net/fusioncharts/92trD/

<div id="chart-container">FusionCharts will render here</div>
<!-- Sample for : Plotting the secondary y-axis on the left side of the chart.

    Attributes:
        primaryAxisOnLeft : Setting this attribute to 0 reverses the position of the primary axis.

 -->

FusionCharts.ready(function() {
  var revenueChart = new FusionCharts({
    type: 'mscombidy2d',
    renderAt: 'chart-container',
    width: '600',
    height: '350',
    dataFormat: 'json',
    dataSource: {
      "chart": {
        "caption": "Revenues and Profits",
        "subCaption": "For last year",
        "xAxisname": "Month",
        "pYAxisName": "Amount (In USD)",
        "sYAxisName": "Profit %",
        "numberPrefix": "$",
        "sNumberSuffix": "%",
        "sYAxisMaxValue": "50",
        "primaryAxisOnLeft": "0",
        "theme": "fusion"
      },
      "categories": [{
        "category": [{
          "label": "Jan"
        }, {
          "label": "Feb"
        }, {
          "label": "Mar"
        }, {
          "label": "Apr"
        }, {
          "label": "May"
        }, {
          "label": "Jun"
        }, {
          "label": "Jul"
        }, {
          "label": "Aug"
        }, {
          "label": "Sep"
        }, {
          "label": "Oct"
        }, {
          "label": "Nov"
        }, {
          "label": "Dec"
        }]
      }],
      "dataset": [{
        "seriesName": "Revenues",
        "data": [{
          "value": "16000"
        }, {
          "value": "20000"
        }, {
          "value": "18000"
        }, {
          "value": "19000"
        }, {
          "value": "15000"
        }, {
          "value": "21000"
        }, {
          "value": "16000"
        }, {
          "value": "20000"
        }, {
          "value": "17000"
        }, {
          "value": "22000"
        }, {
          "value": "19000"
        }, {
          "value": "23000"
        }]
      }, {
        "seriesName": "Profits",
        "renderAs": "area",
        "showValues": "0",
        "data": [{
          "value": "4000"
        }, {
          "value": "5000"
        }, {
          "value": "3000"
        }, {
          "value": "4000"
        }, {
          "value": "1000"
        }, {
          "value": "7000"
        }, {
          "value": "1000"
        }, {
          "value": "4000"
        }, {
          "value": "1000"
        }, {
          "value": "8000"
        }, {
          "value": "2000"
        }, {
          "value": "7000"
        }]
      }, {
        "seriesName": "Profit %",
        "parentYAxis": "S",
        "renderAs": "line",
        "showValues": "0",
        "data": [{
          "value": "25"
        }, {
          "value": "25"
        }, {
          "value": "16.66"
        }, {
          "value": "21.05"
        }, {
          "value": "6.66"
        }, {
          "value": "33.33"
        }, {
          "value": "6.25"
        }, {
          "value": "25"
        }, {
          "value": "5.88"
        }, {
          "value": "36.36"
        }, {
          "value": "10.52"
        }, {
          "value": "30.43"
        }]
      }]
    }
  });

  revenueChart.render();
});
本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请点击举报
打开APP,阅读全文并永久保存 查看更多类似文章
猜你喜欢
类似文章
【热】打开小程序,算一算2024你的财运
FusionCharts简单教程(六)------加载外部Logo
FusionCharts在Java中的基本使用
用ChartDirector创建基于web的图表--水平双向条形图
改进Excel图表的10×10个贴士(转贴+翻译)
Polar plot
【python】Pandas中DataFrame基本函数整理(全)
更多类似文章 >>
生活服务
热点新闻
分享 收藏 导长图 关注 下载文章
绑定账号成功
后续可登录账号畅享VIP特权!
如果VIP功能使用有故障,
可点击这里联系客服!

联系客服