This is a migrated thread and some comments may be shown as answers.

Line chart has no line, all points disconnected.

1 Answer 76 Views
Charts
This is a migrated thread and some comments may be shown as answers.
Rich
Top achievements
Rank 1
Rich asked on 06 Feb 2013, 06:11 PM
I am trying to make a line chart where the categoryAxis has a baseUnit of "month".

The data is an array of objects

[0].price = 34
[0].priceDate = javascriptDate

The data bind and the chart is there but it looks like a bunch of points with none of them connected by a line. OR depending on the data, some points are connected.


$("#previewChart").kendoChart({
                theme: "blueOpal",
                title: {
                    text: customDataViewModel.CustomDataName
                },
                legend: {
                    visible:false
                },
                chartArea: {
                    width: 680,
                    height:380
                },
                plotArea: {
                    margin: { bottom: 10, right: 100}
                },               
                dataSource: wth,
                series: [{
                    type:"line",
                    field: "price"
                }],
                categoryAxis: {
                    type: "date",
                    field: "priceDate",
                    baseUnit: "month",
                    labels: {
                        format: "MMM/yy",
                        title:"",
                        rotation:-90
                    }
                },
                valueAxis: {
                    
                },
                tooltip: {
                    visible: true,
                    template: "Price: #= value #<br/>Date: #= kendo.toString(category, 'MMM/yyyy') #"
                }
            });                        
        });      

I need every point to show and for them to be connected by a line.

1 Answer, 1 is accepted

Sort by
0
Iliana Nikolova
Telerik team
answered on 08 Feb 2013, 04:18 PM
Hi Rich,

I have already answered to your support ticket on the same subject, however I am pasting my reply here too so the other users who are interested in the same can read it: 

In order to achieve the desired outcome you should set missingValues: "interpolate" in the series''definition. For your convenience here is a jsBin example which demonstrates this in action.

Regards,
Iliana Nikolova
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
Charts
Asked by
Rich
Top achievements
Rank 1
Answers by
Iliana Nikolova
Telerik team
Share this question
or