如何从条形图中删除轴和其他信息

How to remove axis, and other information from Bar Chart?

本文关键字:其他 信息 删除 条形图      更新时间:2023-09-26

我需要画一个折线图,但只是一个没有轴、值的折线图​​,等等。最后只有图表和百分比。

Q: 如何从图形中删除所有项目,指示轴、轴等。您只需要留下一个折线图和兴趣即可。

$('#audience').jqChart({
                legend: { visible: false },
                border: { visible: false },
                title:
                {
                    text: 'Chart Title',
                    font: '12px sans-serif',
                    lineWidth: 1,
//                    strokeStyle: 'black',
                    fillStyle: 'white'
                },
                animation: { duration: 1 },
                series: [
                    {
                        pointWidth: 0.2,
                        type: 'bar',
                        fillStyle: '#7fbbe5',
                        data: [['A', 33]],
                        labels: {
                            stringFormat: ' %s %%',
                            valueType: 'dataValue',
                            font: '11px sans-serif',
                            fillStyle: 'white'
                        },
                        tickOptions: {
                            showGridline: false
                        }
                    },
                    {
                        pointWidth: 0.2,
                        type: 'bar',
                        fillStyle: '#92b5c7',
                        data: [['A', 67]],
                        tickOptions: {
                            showGridline: false
                        },
                        labels: {
                            stringFormat: ' %s %%',
                            valueType: 'dataValue',
                            font: '11px sans-serif',
                            fillStyle: 'white'
                        }
                    }
                ]
            });

我有一个图像,我在哪里展示,我拥有什么,我需要什么:http://i57.tinypic.com/2h3x3yx.jpg

您可以拼接jqChart轴-

 var axes = $('#jqChartDiv').jqChart('option', 'axes');
//remove all series
axes.splice(0, axes.length );