// 基于准备好的dom,初始化echarts实例 var myChart = echarts.init(document.getElementById('v3'));
// 指定图表的配置项和数据 var option = {
title : { text: 'What do you think about the accuracy of our recommendation system,compared to the information you actually need?', x:'center', textStyle:{ fontSize:8, } }, tooltip : { trigger: 'item', formatter: "{a}
{b} : {c} ({d}%)" }, legend: { orient: 'vertical', x:'right', y:'center', data: ['Over 80%','About 50%','Less than 20%','others'] }, series : [ { name: 'Access Sources', type: 'pie', radius : '55%', center: ['50%', '60%'], data:[ {value:75, name:'Over 80%'}, {value:25, name:'About 50%'}, ], itemStyle: { emphasis: { shadowBlur: 10, shadowOffsetX: 0, shadowColor: 'rgba(0, 0, 0, 0.5)' } } } ]
};
// 使用刚指定的配置项和数据显示图表。 myChart.setOption(option);