Incubator-echarts: Hide zero value record

Created on 19 Jan 2017  ·  2Comments  ·  Source: apache/incubator-echarts

Hi,

Please see the picture i want to hide zero value record. If any possible?

Thanks in advance
2017-01-19_114247

stale

Most helpful comment

When setting the series data, you can use:

{
    value: (yourValue || '-')
}

So it sets the value when it's not zero or undefined, and otherwise it sets a -, which will not be shown as a label.

All 2 comments

I think you can try https://ecomfe.github.io/echarts-doc/public/en/option.html#series-bar.label.normal.formatter, where you can use callback function to return ''; for zero value.

When setting the series data, you can use:

{
    value: (yourValue || '-')
}

So it sets the value when it's not zero or undefined, and otherwise it sets a -, which will not be shown as a label.

Was this page helpful?
0 / 5 - 0 ratings