score:2

Accepted answer

you could define your yaxis values as numbers. in my code "yes" = 2 and "no" = 1.

data: [2, 1, 2, 1]

then use yaxist.ticks.callback to return meaningful tick labels

yaxes: [{
  ticks: {
    beginatzero: true,
    stepsize: 1,
    callback: value => {
      if (value == 0) {
        return '';
      }
      return value == 1 ? 'no' : 'yes';
    }
  }
}]

please have a look at the following stackblitz


Related Query

More Query from same tag