Accepted answer

the problem is that you have only one dataset and your code use the index of legend item clicked to hide datasets[index].

on the contrary you need to hide single item data as below:

var meta = chart.getdatasetmeta(0);
var item =[index];

check the fiddle updated:

Related Query

More Query from same tag