Echart have no presentation options for null values in trends or line charts
See original GitHub issueOne-line summary [问题简述]
Echarts shoud have options for null value presentation. At the moment (echart v4.2.0.rc1), Echart only supports show or hide option using series.connectNulls
boolean, if set to true it will connect through null value point to its next and previous points. If it is set to false it will show this part of chart hidden or empty.
Version & Environment [版本及环境]
ECharts version [ECharts version]: v4.2.0.rc Browser version [browser type and version]: Chrome 69, but probably doesn’t matter OS Version [operating system type and version]: Ubuntu but probably doesn’t matter
Expected behaviour [期望结果]
- It should at least allow us to
connectNulls
differently then the traditional line. Because it is very important to differentiate in many applications that there is actually no data and this connection represents a missing value. TheconnectNulls
line could be dashed ----- or dotted or any new ideas to represent missing data. Something like{connectNulls:'dashed'}
or{connectNulls:'dotted'}
ConnectNulls
option should also work in time axis type by detecting automatically that at certain time there is no data point available in the source or array of data points. For category type axis it should also detect that there is an axis value but no data defined for it in the data array. Hence that point will also be considered as null point.
ECharts option [ECharts配置项]
option = {
xAxis: {
type: 'category',
data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
},
yAxis: {
type: 'value'
},
series: [{
data: [820, 932, null, 934, 1290, 1330, 1320],
type: 'line',
connectNulls:false, // this will show empty area between 932 and 934 output below
}]
};
Other comments [其他信息]
Issue Analytics
- State:
- Created 5 years ago
- Reactions:38
- Comments:18 (3 by maintainers)
Top Results From Across the Web
Basic Line - Common Charts - How To Guides - Apache ECharts
In ECharts, we use '-' to represent null data, It is applicable for data in other series. option = { xAxis: { data:...
Read more >Line chart options | Looker - Google Cloud
Overview of visualization menu options for line charts. ... Series Positioning; Grid Layout; Line Interpolation; Plot Null Values; Swap X and Y; Hide...
Read more >Range and scale on visual types in QuickSight
This option is available for the value axes on bar charts, combo charts, line charts, and scatter plots. By default, the axis range...
Read more >A Complete Guide to Line Charts | Tutorial by Chartio
When the line chart is missing information for certain bins, gaps in the record may be interpreted as phantom values if the line...
Read more >How to Make a Chart or Graph in Excel [With Video Tutorial]
You can make more than just bar or line charts in Microsoft Excel, ... magnitude of a trend between two or more values...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Any updates regarding this?
This issue will be possibly solved by one of our OSPP project.