Hiding nulls in line chart and connecting points - Built-in feature in V5.8
Introduction:
Remove points when they are null (currently they are translated to zeroes).
And connect points that have null values between them
Copy the following script into the widget script:
widget.on('beforeviewloaded',function(w,args){
args.options.plotOptions.series.connectNulls= true; // connect points that have null value in between
// transform all zeroes that came from null back to nulls
args.options.series.forEach(function(ser){
ser.data.forEach(function(d){
if(!d.marker && d.y == 0){
d.y = null
}
})
})
})
In case one does not want to connect the null just comment out the line:
//args.options.plotOptions.series.connectNulls= true; // connect points that have null value in between
Example:
before:
after:
-
Hi Everyone,
I'm pleased to inform you that the new Sisense version V5.8 has this capability as a built in feature.
In V5.8 chart are defined to ignore null values and continue the chart when values exist.
V5.8 is now available for download.
Please make sure to back up everything prior to upgrading, for this, please see:
https://support.sisense.com/entries/62020374-Back-up-your-work-
Here is a link to V5.8 announcement with the upgrade file:
https://support.sisense.com/entries/69736944-Sisense-V5-8-is-here-
Best,
Inbal
Please sign in to leave a comment.
Comments
1 comment