# Have Chart or Easy chart graph only when tag value is true

**URL:** <https://forum.inductiveautomation.com/t/have-chart-or-easy-chart-graph-only-when-tag-value-is-true/52193>\
**Category:** Ignition\
**Created:** [October 20, 2021, 11:18pm UTC](https://forum.inductiveautomation.com/t/have-chart-or-easy-chart-graph-only-when-tag-value-is-true/52193 "2021-10-20T23:18:36Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![user62](https://avatars.discourse-cdn.com/v4/letter/u/e47774/32.png) [@user62](https://forum.inductiveautomation.com/u/user62)\
**Post date:** [October 20, 2021, 11:18pm UTC](https://forum.inductiveautomation.com/t/have-chart-or-easy-chart-graph-only-when-tag-value-is-true/52193/1 "2021-10-20T23:18:36Z")

</div>

I need an elapsed time x axis. The time would be according to a historical boolean tag going from true\>false and vice-versa. So when tag goes true, plot data. When tag goes false, stop plotting data.  
I have used the information here: [Report Component - Timeseries Chart - Ignition User Manual 7.9 - Ignition Documentation](https://docs.inductiveautomation.com/display/DOC79/Report+Component+-+Timeseries+Chart)  
Also tried doing it to an Easy Chart.  
Any help is very appreciated, thanks.

\*\*using version 7.9.13

---

<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:** [October 21, 2021, 12:44am UTC](https://forum.inductiveautomation.com/t/have-chart-or-easy-chart-graph-only-when-tag-value-is-true/52193/2 "2021-10-21T00:44:40Z")

</div>

The Tag Historian has no proper way to do this. The mechanism in Ignition for this sort of behavior is a transaction group, part of the SQL Bridge module. You would set up values to record into a dedicated table at intervals, but only when a trigger condition is true. You then plot the values from the table using DB pens in the EasyChart instead of Tag Pens.

---

<div class="post-metadata">

**Author:** ![user62](https://avatars.discourse-cdn.com/v4/letter/u/e47774/32.png) [@user62](https://forum.inductiveautomation.com/u/user62)\
**Post date:** [October 21, 2021, 1:12am UTC](https://forum.inductiveautomation.com/t/have-chart-or-easy-chart-graph-only-when-tag-value-is-true/52193/3 "2021-10-21T01:12:49Z")

</div>

Thank you so much. Will look into that!

---

<div class="post-metadata">

**Author:** ![jlandwerlen](https://avatars.discourse-cdn.com/v4/letter/j/bc8723/32.png) [@jlandwerlen](https://forum.inductiveautomation.com/u/jlandwerlen)\
**Post date:** [October 21, 2021, 2:29pm UTC](https://forum.inductiveautomation.com/t/have-chart-or-easy-chart-graph-only-when-tag-value-is-true/52193/4 "2021-10-21T14:29:09Z")

</div>

I would still use tag history. But, manage the data in scripting… build a dataset the way you like it. Then use this data for your chart.

---

<div class="post-metadata">

**Author:** ![user62](https://avatars.discourse-cdn.com/v4/letter/u/e47774/32.png) [@user62](https://forum.inductiveautomation.com/u/user62)\
**Post date:** [October 29, 2021, 10:51pm UTC](https://forum.inductiveautomation.com/t/have-chart-or-easy-chart-graph-only-when-tag-value-is-true/52193/5 "2021-10-29T22:51:30Z")

</div>

I have done that then used that same dataset on a Classic chart but it plots continuously regardless of gaps in timestamp. Thanks!

---

<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:** [October 29, 2021, 11:01pm UTC](https://forum.inductiveautomation.com/t/have-chart-or-easy-chart-graph-only-when-tag-value-is-true/52193/6 "2021-10-29T23:01:38Z")

</div>

Check that you are using the pen renderer “Line w/ Gaps”.
