配置项如下
app.title = '极坐标系下的堆叠柱状图';
option = {
angleAxis: {
show: true
},
radiusAxis: {
type: 'category',
data: ['周一', '周二', '周三', '周四'],
z: 10,
show: false
},
polar: {
// 关于radius,文档里描述的是
// Array.<number|string>:数组的第一项是内半径,第二项是外半径。每一项遵从上述 number string 的描述。
radius: ['10%', '100%'],
//radius: '100%'
},
series: [{
type: 'bar',
data: [1, 2, 3, 4],
coordinateSystem: 'polar',
itemStyle: {
barBorderRadius: 50
},
name: 'A',
stack: 'b'
}, {
type: 'bar',
data: [2, 4, 6, 8],
coordinateSystem: 'polar',
name: 'B',
stack: 'a'
}, {
type: 'bar',
data: [1, 2, 3, 4],
coordinateSystem: 'polar',
name: 'C',
stack: 'a'
}],
legend: {
show: true,
data: ['A', 'B', 'C']
}
};