```js
var selectedData = [];
myChart.setOption({
// ...
series: [{
id: 'all'
data: [ ... ]
}, {
id: 'selected',
data: selectedData
z: 1000
}]
};
myChart.on('click', function (params) {
if (selectedData.indexOf(params.dataIndex) < 0) {
selectedData.push(params.value);
})
myChart.setOption({
series: {
id: 'selected',
data: selectedData
}
})
})
```
[ Full content available at:
https://github.com/apache/incubator-echarts/issues/9029 ]
This message was relayed via gitbox.apache.org for [email protected]