Table of Contents
<html> <head> <title>My first chart using FusionCharts Suite XT</title> https://cdn.fusioncharts.com/fusioncharts/latest/fusioncharts.js https://cdn.fusioncharts.com/fusioncharts/latest/themes/fusioncharts.theme.fusion.js <script type="text/javascript"> FusionCharts.ready(function(){ var chartObj = new FusionCharts({ type: 'logmscolumn2d', renderAt: 'chart-container', width: '500', height: '350', dataFormat: 'json', dataSource: { "chart": { "theme": "fusion", "caption": "Store footfall vs Online visitors ", "subCaption": "Last Year", "xAxisName": "Quarter", "yAxisName": "No of visitors", "showXAxisLine": "1", "axisLineAlpha": "10" }, "categories": [{ "category": [{ "label": "Q1" }, { "label": "Q2" }, { "label": "Q3" }, { "label": "Q4" }] }], "dataset": [{ "seriesname": "Total footfalls", "data": [{ "value": "126734" }, { "value": "159851" }, { "value": "197393" }, { "value": "168560" }, { "value": "199428" }] }, { "seriesname": "Online Visits", "data": [{ "value": "1126059" }, { "value": "1292145" }, { "value": "1496849" }, { "value": "1460249" }, { "value": "1083962" }] }] } } ); chartObj.render(); }); </script> </head> <body> <div id="chart-container">FusionCharts XT will load here!</div> </body> </html>2. Open your JSON file. Then insert these lines:
{
"chart": {
"theme": "fusion",
"caption": "Store footfall vs Online visitors ",
"subCaption": "Last Year",
"xAxisName": "Quarter",
"yAxisName": "No of visitors",
"showXAxisLine": "1",
"axisLineAlpha": "10"
},
"categories": [
{
"category": [
{
"label": "Q1"
},
{
"label": "Q2"
},
{
"label": "Q3"
},
{
"label": "Q4"
}
]
}
],
"dataset": [
{
"seriesname": "Total footfalls",
"data": [
{
"value": "126734"
},
{
"value": "159851"
},
{
"value": "197393"
},
{
"value": "168560"
},
{
"value": "199428"
}
]
},
{
"seriesname": "Online Visits",
"data": [
{
"value": "1126059"
},
{
"value": "1292145"
},
{
"value": "1496849"
},
{
"value": "1460249"
},
{
"value": "1083962"
}
]
}
]
} 3. Finally, go to your XML file. Insert this code: <chart theme="fusion" caption="Store footfall vs Online visitors " subcaption="Last Year" xaxisname="Quarter" yaxisname="No of visitors" showxaxisline="1" axislinealpha="10">
<categories>
<category label="Q1" />
<category label="Q2" />
<category label="Q3" />
<category label="Q4" />
</categories>
<dataset seriesname="Total footfalls">
<set value="126734" />
<set value="159851" />
<set value="197393" />
<set value="168560" />
<set value="199428" />
</dataset>
<dataset seriesname="Online Visits">
<set value="1126059" />
<set value="1292145" />
<set value="1496849" />
<set value="1460249" />
<set value="1083962" />
</dataset>
</chart> <html> <head> <title>My first chart using FusionCharts Suite XT</title> https://cdn.fusioncharts.com/fusioncharts/latest/fusioncharts.js https://cdn.fusioncharts.com/fusioncharts/latest/themes/fusioncharts.theme.fusion.js <script type="text/javascript"> FusionCharts.ready(function(){ var chartObj = new FusionCharts({ type: 'line', renderAt: 'chart-container', width: '680', height: '390', dataFormat: 'json', dataSource: { "chart": { "theme": "fusion", "caption": "Total footfall in Bakersfield Central", "subCaption": "Last week", "xAxisName": "Day", "yAxisName": "No. of Visitors", "lineThickness": "2" }, "data": [{ "label": "Mon", "value": "15123" }, { "label": "Tue", "value": "14233" }, { "label": "Wed", "value": "23507" }, { "label": "Thu", "value": "9110" }, { "label": "Fri", "value": "15529" }, { "label": "Sat", "value": "20803" }, { "label": "Sun", "value": "19202" } ], "trendlines": [{ "line": [{ "startvalue": "18500", "color": "#29C3BE", "displayvalue": "Average{br}weekly{br}footfall", "valueOnRight": "1", "thickness": "2" }] }] } }); chartObj.render(); }); </script> </head> <body> <div id="chart-container">FusionCharts XT will load here!</div> </body> </html>2. Then open your JSON file. Insert these lines:
{
"chart": {
"theme": "fusion",
"caption": "Total footfall in Bakersfield Central",
"subCaption": "Last week",
"xAxisName": "Day",
"yAxisName": "No. of Visitors",
"lineThickness": "2"
},
"data": [
{
"label": "Mon",
"value": "15123"
},
{
"label": "Tue",
"value": "14233"
},
{
"label": "Wed",
"value": "23507"
},
{
"label": "Thu",
"value": "9110"
},
{
"label": "Fri",
"value": "15529"
},
{
"label": "Sat",
"value": "20803"
},
{
"label": "Sun",
"value": "19202"
}
],
"trendlines": [
{
"line": [
{
"startvalue": "18500",
"color": "#29C3BE",
"displayvalue": "Average{br}weekly{br}footfall",
"valueOnRight": "1",
"thickness": "2"
}
]
}
]
} 3. Finally, go to your XML file. Add this code: <chart theme="fusion" caption="Total footfall in Bakersfield Central" subcaption="Last week" xaxisname="Day" yaxisname="No. of Visitors" linethickness="2">
<set label="Mon" value="15123" />
<set label="Tue" value="14233" />
<set label="Wed" value="23507" />
<set label="Thu" value="9110" />
<set label="Fri" value="15529" />
<set label="Sat" value="20803" />
<set label="Sun" value="19202" />
<trendlines>
<line startvalue="18500" color="#29C3BE" displayvalue="Average{br}weekly{br}footfall" valueonright="1" thickness="2" />
</trendlines>
</chart> To create pie charts and generate statistical data, you’ll find this list of the best…
To implement FusionCharts in a dynamically resizing flexbox layout, ensure that the chart's dimensions are…
At FusionCharts, we believe in empowering developers and businesses with cutting-edge data visualization tools that…
Ever had a data set that seemed more complicated than a Rubik's cube? You’re not…
We’ve all seen them in textbooks or presentations—those overlapping circles that simplify complex information into…
We’re excited to announce the upcoming release of FusionCharts v4.1—a groundbreaking step forward in the…