FusionCharts - Vertical Zero Plane in charts with numeric x-axis

Showing only specific data values of a chart

by Moonmi Sonowal

HTML

<script src="http://static.fusioncharts.com/code/latest/fusioncharts.js"></script>
<script src="http://static.fusioncharts.com/code/latest/fusioncharts.charts.js"></script>
<script src="http://static.fusioncharts.com/code/latest/themes/fusioncharts.theme.fint.js"></script>
<!-- In charts with numeric x-axis (XY Plot or Scatter, Bubble), you can display Vertical Zero Plane in a chart. Attributes: # showVZeroPlane # vZeroPlaneColor # vZeroPlaneAlpha # vZeroPlaneThickness -->
<div id="chart-container">FusionCharts will render here</div>

JavaScript

FusionCharts.ready(function () {
    var profitChart = new FusionCharts({
        type: 'scatter',
        renderAt: 'chart-container',
        id: 'myChart',
        width: '500',
        height: '350',
        dataFormat: 'json',
        dataSource: {
            "chart": {
                "animation": "1",
                    "labeldisplay": "WRAP",
                    "showyaxisvalues": "1",
                    "xaxisminvalue": "-0.010062",
                    "xaxismaxvalue": "0.006462",
                    "yaxisminvalue": "-0.0202",
                    "yaxismaxvalue": "0.009",
                    "adjustdiv": "0",
                    "caption": "Fitted Line Plot: 102-1 - Intra Inline Gage  Crank #1 - X1  -0.00359 + 0.95326 × 100-1 - CNC  Crank AVG ; R²  0.9131",
                    "xaxisname": "100-1 - CNC  Crank AVG",
                    "yaxisname": "102-1 - Intra Inline Gage  Crank #1 - X1",
                    "bgcolor": "FFFFFF",
                    "canvasbgcolor": "F3F5F5",
                    "numdivlines": "5",
                    "showzeroplane": "0",
                    "decimals": "4",
                    "chartleftmargin": "0",
                    "chartrightmargin": "50",
                    "charttopmargin": "10",
                    "chartbottommargin": "10",
                    "xaxislabelmode": "categories"
            },
                "categories": [{
                "category": [{
                    "x": "-0.0099",
                        "label": "-0.0099 "
                }, {
                    "x": "-0.00585",
                        "label": "-0.00585 "
                }, {
                    "x": "-0.0018",
                        "label": "-0.0018 "
                }, {
                    "x": "0.00225",
                        "label": "0.00225 "
                }, {
                    "x": "0.0063",
                        "label": "0.0063 "
                }]
            }],
                "dataset": [{
             ...