# Any solution to get a discrete LineSeries (or something other), i.e. with gaps?

## Any solution to get a discrete LineSeries (or something other), i.e. with gaps?

Hi,

What if I need a gap within a LineSeries?

I think LineSeries cannot be discrete. So, I am just asking - is there any solution? Sure, apart from two LineSeries for one gap, three LineSeries for two gaps, etc. I need just one Series, but with gaps.

2. You can specify values of 'undefined' to halt the drawing of a line.

Scott.

3. Hi Scott,

Thanks a lot for the answer.

Previously I tried with nulls. But, anyways, I am not sure where I should specify 'undefined' to get a required gap.

Please look at the screenshot. I need a gap between 25 and 75.
2.JPG
Here is a test case. Could you clarify, please, where should I specify 'undefined' to get a gap between 25 and 75?

Test Case
Code:
```<html>
<title>Chart Gaps</title>

<script type="text/javascript" src="../ext-all-debug.js"></script>

<script type="text/javascript">
Ext.create("Ext.chart.Chart", {
renderTo: Ext.getBody(),
height: 400,
width: 400,
axes: [{
position: "bottom",
title: "X",
fields: ["x"],
type: "Numeric"
}, {
position: "left",
title: "Y",
fields: ["y"],
type: "Numeric"
}],
series: [{
title: "LineSeries",
xField: "x",
yField: "y",
type: "line"
}],
store: {
fields: [{
name: "x"
}, {
name: "y"
}],
proxy: {
data: [{
"x": 0,
"y": 0
}, {
"x": 25,
"y": 25
}, {
"x": 50,
"y": undefined /* Where should I specify 'undefined' to get a gap between 25 and 75? */
}, {
"x": 75,
"y": 75
}, {
"x": 100,
"y": 100
}],
type: 'memory'
}
}
});
});
</script>
<body>

</body>
</html>```

4. My mistake.. It seems that undefined only works if it is at the end as shown:

If the values are in the middle, the markers are omitted and the line continues.

You would most likely need to override or create a new series. I see there is a bug report for this:

It is slated for 4.2 release (no public date)

Regards,
Scott.

5. Great, thanks for the information!

6. Originally Posted by scottmartin
You can specify values of 'undefined' to halt the drawing of a line.
Hi Scott,

What about to have the same behavior for nulls? The nulls come from a server. Then we could avoid setting up a convert handler to get undefined instead of nulls.

7. This is slated for 4.2. I have noted that you would like to have null as an option.

Scott.

8. Thank you very much, Scott.

9. Hi Scott,

Re: LineSeries with gaps

Someone found out that "false" as a value produces a gap. Here are more details and a working sample.
http://www.sencha.com/forum/showthre...l=1#post920507