# Easy chart renderer change is not reflecting

**URL:** <https://forum.inductiveautomation.com/t/easy-chart-renderer-change-is-not-reflecting/44737>\
**Category:** Ignition\
**Tags:** vision, scripting, ignition80\
**Created:** [March 22, 2021, 5:29am UTC](https://forum.inductiveautomation.com/t/easy-chart-renderer-change-is-not-reflecting/44737 "2021-03-22T05:29:18Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Premnath.K](https://avatars.discourse-cdn.com/v4/letter/p/b487fb/32.png) [@Premnath.K](https://forum.inductiveautomation.com/u/Premnath.K)\
**Post date:** [March 22, 2021, 5:29am UTC](https://forum.inductiveautomation.com/t/easy-chart-renderer-change-is-not-reflecting/44737/1 "2021-03-22T05:29:18Z")

</div>

Hi All,

I tried changing the default renderer type (StandardXYItemRenderer) to XYStepRenderer as the value where plotted wrong in StandardXYItemRenderer. After changing the renderer type to XYStepRenderer the plotted graph is not changing its same as StandardXYItemRenderer. But intrestingly when i print the render its showing XYStepRenderer.

```auto
from org.jfree.chart import renderer
	from org.jfree.chart.renderer.xy import XYStepRenderer
	from org.jfree.chart.renderer.xy import StandardXYItemRenderer

	
	plot = chart.getPlot()
	renderer = plot.getRenderer()
	print renderer
	print str(type(renderer))+"this was"
	renderer1 = XYStepRenderer()
	print type(renderer1)
	plot.setRenderer(renderer1)
	plot = chart.getPlot()
	renderer = plot.getRenderer()
	print str(type(renderer))+"this is it"
	print type(self)

```

output  
org.jfree.chart.renderer.xy.StandardXYItemRenderer@7b027c09  
\<type ‘org.jfree.chart.renderer.xy.StandardXYItemRenderer’\>this was  
\<type ‘org.jfree.chart.renderer.xy.XYStepRenderer’\>  
\<type ‘org.jfree.chart.renderer.xy.XYStepRenderer’\>this is it  
\<type ‘com.inductiveautomation.factorypmi.application.components.PMIEasyChart’\>

But the output graph is the same as StandardXYItemRenderer  
So I tried in the “chart” component surprisingly I am able to get the output there with the same code.  
attached screenshot of both.

My question is  
So why in an easy chart the chart is not changing to XYStepRenderer??

EASY chart:-  
 ![easy chart](https://us1.discourse-cdn.com/inductiveautomation/original/3X/9/6/968cb00ddccb0a2495d2c7642d50f3fa43c8e9a5.jpeg)

Chart:-  
 ![chart](https://us1.discourse-cdn.com/inductiveautomation/original/3X/8/8/887b67a618a1360b142535784afaed87f23a89f1.jpeg)

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [March 22, 2021, 12:30pm UTC](https://forum.inductiveautomation.com/t/easy-chart-renderer-change-is-not-reflecting/44737/2 "2021-03-22T12:30:05Z")

</div>

Where is this code running? If not called from the EasyChart’s configureChart method, I wouldn’t expect it to work.

---

<div class="post-metadata">

**Author:** ![Premnath.K](https://avatars.discourse-cdn.com/v4/letter/p/b487fb/32.png) [@Premnath.K](https://forum.inductiveautomation.com/u/Premnath.K)\
**Post date:** [March 22, 2021, 12:46pm UTC](https://forum.inductiveautomation.com/t/easy-chart-renderer-change-is-not-reflecting/44737/3 "2021-03-22T12:46:38Z")

</div>

Yes yes it’s running in the configured chart method only

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [March 22, 2021, 3:53pm UTC](https://forum.inductiveautomation.com/t/easy-chart-renderer-change-is-not-reflecting/44737/4 "2021-03-22T15:53:37Z")

</div>

Does your easy chart have subplots? The `getPlot()` call might be returning a `CombinedDomainXYPlot` or something similar, and each of its plots might need to have the renderer set. Or, you might need to assign the renderer to the correct series; it’s been a while since I’ve really gotten into JFreeChart.

---

<div class="post-metadata">

**Author:** ![Premnath.K](https://avatars.discourse-cdn.com/v4/letter/p/b487fb/32.png) [@Premnath.K](https://forum.inductiveautomation.com/u/Premnath.K)\
**Post date:** [March 23, 2021, 4:42am UTC](https://forum.inductiveautomation.com/t/easy-chart-renderer-change-is-not-reflecting/44737/5 "2021-03-23T04:42:11Z")

</div>

Thanks for the input, But there is only one subplot to which the pen is assigned.  
I tried the following

```auto
	plot = chart.getPlot()
	print plot.getPlotType()
	print plot.isSubplot()

```

Output:-  
XY Plot  
False
