# Vision Chart: Interpolation and visual bands

**URL:** <https://forum.inductiveautomation.com/t/vision-chart-interpolation-and-visual-bands/88491>\
**Category:** Ignition\
**Tags:** ignition81, vision\
**Created:** [April 8, 2024, 4:30am UTC](https://forum.inductiveautomation.com/t/vision-chart-interpolation-and-visual-bands/88491 "2024-04-08T04:30:45Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sasi\_Rai](https://avatars.discourse-cdn.com/v4/letter/s/ed655f/32.png) [@Sasi\_Rai](https://forum.inductiveautomation.com/u/Sasi_Rai)\
**Post date:** [April 8, 2024, 4:30am UTC](https://forum.inductiveautomation.com/t/vision-chart-interpolation-and-visual-bands/88491/1 "2024-04-08T04:30:45Z")

</div>

Hi Everyone,

Given below is my Chart, in Vision. It displays a forecast of what the value of a certain Variable will be, in half hour intervals, the next 7 days. Just like a 7 days' temperature forecast.  
 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/6/2/62221ede9d07ac2de2cd35e09cb5d0c00489991d.png)

Even though we see some slopes, the actual value changes are very much discreet/step like. A typical forecast would be something like: 0, 20, 20, 0, -20, -40, -60, -60, -20-, 0, etc......... Is there a way to make the chart steplike?

And also, I would like to create bands, like so:

 ![Price Intensity Bands](https://us1.discourse-cdn.com/inductiveautomation/original/3X/a/5/a5aa73fa989e87bfcf0f740da11d3833ff2b92bc.jpeg)  
How can I do this?

Any guidance will be very much appreciated. Thank you.

---

<div class="post-metadata">

**Author:** ![justinedwards.jle](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/justinedwards.jle/32/37854_2.png) [@justinedwards.jle](https://forum.inductiveautomation.com/u/justinedwards.jle)\
**Post date:** [April 8, 2024, 4:58pm UTC](https://forum.inductiveautomation.com/t/vision-chart-interpolation-and-visual-bands/88491/2 "2024-04-08T16:58:00Z")

</div>

Just for clarification, this is a Chart and not an Easy Chart?

---

<div class="post-metadata">

**Author:** ![Sasi\_Rai](https://avatars.discourse-cdn.com/v4/letter/s/ed655f/32.png) [@Sasi\_Rai](https://forum.inductiveautomation.com/u/Sasi_Rai)\
**Post date:** [April 8, 2024, 11:13pm UTC](https://forum.inductiveautomation.com/t/vision-chart-interpolation-and-visual-bands/88491/3 "2024-04-08T23:13:11Z")

</div>

Hi Justin. Yup, this is a Chart. I haven't tried the Easy Chart yet.

---

<div class="post-metadata">

**Author:** ![justinedwards.jle](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/justinedwards.jle/32/37854_2.png) [@justinedwards.jle](https://forum.inductiveautomation.com/u/justinedwards.jle)\
**Post date:** [April 9, 2024, 12:32am UTC](https://forum.inductiveautomation.com/t/vision-chart-interpolation-and-visual-bands/88491/4 "2024-04-09T00:32:24Z")

</div>

> [@Sasi\_Rai](#):
>
> Is there a way to make the chart steplike?

• Right click on the chart and select: "Chart Customizer"  
• Switch to the "Dataset Properties" tab, select the dataset, and change the renderer to "XY Step Renderer"  
 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/e/b/eb5390ddead23b75f678e4ef7869c47c60749d95.png)

> [@Sasi\_Rai](#):
>
> also, I would like to create bands, like so:

Use interval markers for this purpose.  
**Example:**

```auto
# configureChart Extension Function
#def configureChart(self, chart):
	# Import interval marker class
	from org.jfree.chart.plot import IntervalMarker
	
	# Range 0 to 12 earth green
	chart.plot.addRangeMarker(IntervalMarker(0, 12, system.gui.color(56, 94, 15, 80)))
	
	# Range 12 to 24 teal
	chart.plot.addRangeMarker(IntervalMarker(12, 24, system.gui.color(0, 128, 128, 80)))
	
	# Range 24 to 36 light blue
	chart.plot.addRangeMarker(IntervalMarker(24, 36, system.gui.color(173, 216, 230, 140)))
	
	# Range 36 to 48 light grey
	chart.plot.addRangeMarker(IntervalMarker(36, 48, system.gui.color(128, 128, 128, 80)))
	
	# Range 48 to 60 peach
	chart.plot.addRangeMarker(IntervalMarker(48, 60, system.gui.color(255, 218, 185, 80)))
	
	# Range 60 to 72 light orange
	chart.plot.addRangeMarker(IntervalMarker(60, 72, system.gui.color(255, 179, 74, 80)))

	# Range 72 to 96 light red
	chart.plot.addRangeMarker(IntervalMarker(72, 96, system.gui.color(255, 99, 74, 80)))

```

**Result:**

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/3/f/3fc166028870e5bb8e262f3f3f7190d49666ccc0.png)

---

<div class="post-metadata">

**Author:** ![Sasi\_Rai](https://avatars.discourse-cdn.com/v4/letter/s/ed655f/32.png) [@Sasi\_Rai](https://forum.inductiveautomation.com/u/Sasi_Rai)\
**Post date:** [April 10, 2024, 4:24am UTC](https://forum.inductiveautomation.com/t/vision-chart-interpolation-and-visual-bands/88491/5 "2024-04-10T04:24:57Z")

</div>

Hi Justin,

Thank you so much. Everything worked so well! This saved me so much time.

I will buy you a beer or two!!! 😃 Cheers.
