A Horizontal bar chart showing finances information

[No canvas support]

This goes in the documents header:
<script src="RGraph.common.core.js"></script>
<script src="RGraph.hbar.js"></script>
Put this where you want the chart to show up:
<canvas id="cvs" width="600" height="500">
    [No canvas support]
</canvas>
This is the code that generates the chart:
<script>
    // Don't need to assign the chart to a variable
    new RGraph.HBar({
        id: "cvs",
        data: [6,9,13,23,25,31,44],
        options: {
            gutterLeftAutosize: true,
            vmargin: 15,
            backgroundGridHlines: false,
            backgroundGridBorder: false,
            noaxes: true,
            colors: ['#006'],
            unitsPost: '%',
            xmax: 50,
            textAccessible: true,
            labels:[
                'Current account',
                'Mortgage',
                'Savings accounts/cash ISAs',
                'Mobile phone network provider',
                'Internet provider',
                'Energy',
                'Car insurance'
            ]
        }
    }).wave();
</script>

Share on Facebook Share on Twitter

« Back