配置项如下
option = {
title: {
text: 'Awesome Chart'
},
xAxis: {
data: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat']
},
yAxis: {},
series: [{
type: 'line',
data:[220, 182, 191, 234, 290, 330, 310]
}]
};app.title = '天涯情感倾向对比';
option = {
color: ['#3398DB'],
tooltip : {
trigger: 'axis',
axisPointer : { // 坐标轴指示器,坐标轴触发有效
type : 'shadow' // 默认为直线,可选为:'line' | 'shadow'
}
},
grid: {
left: '50%',
right: '10%',
bottom: '20%',
containLabel: true
},
xAxis : [
{
type : 'category',
data : ['+1', '-1', '0'],
axisTick: {
alignWithLabel: true
}
}
],
yAxis : [
{
type : 'value'
}
],
series : [
{
name:'天涯情感倾向对比',
type:'bar',
barWidth: '60%',
data:[67, 33, 0,]
}
]
};