5 <script type="text/javascript">
\r
6 window.onload = function () {
\r
7 var chart = new CanvasJS.Chart("chartContainer", {
\r
9 text: "Top Categories of New Year's Resolution"
\r
11 exportFileName: "CanvasJS Chart",
\r
12 exportEnabled: true,
\r
13 animationEnabled: true,
\r
15 verticalAlign: "bottom",
\r
16 horizontalAlign: "center"
\r
22 toolTipContent: "{legendText}: <strong>{y}%</strong>",
\r
23 indexLabel: "{label} {y}%",
\r
25 { y: 35, legendText: "Health", exploded: true, label: "Health" },
\r
26 { y: 20, legendText: "Finance", label: "Finance" },
\r
27 { y: 18, legendText: "Career", label: "Career" },
\r
28 { y: 15, legendText: "Education", label: "Education" },
\r
29 { y: 5, legendText: "Family", label: "Family" },
\r
30 { y: 7, legendText: "Real Estate", label: "Real Estate" }
\r
39 <script src="../../canvasjs.min.js"></script>
\r
40 <title>CanvasJS Example</title>
\r
43 <div id="chartContainer" style="height: 400px; width: 100%;"></div>
\r