Dear all,
I would like to know if the box-and-whisker chart will update automatically when I use cell updates in the row and column by binding the value to a tag which will change constantly.
If it will not update automatically, i appreciate it if you can give me a suggestion that would help me.
Thank you in advance.
Just to make sure I understand, you are binding the data property of the chart to a dataset tag?
...or you are using a cell update binding to individual tags?
i am using cell update to binding to individual tags
Interesting. Experimenting with this chart, I could only get it to update if the number of rows changed. Changing individual values had no effect. Also, the normal methods for triggering a repaint didn't work, and the data propertyChange event for the chart never happens, even when a row number change causes an update.
As a work around, I created a dataset custom property on the chart's parent container, [the chart itself doesn't have a custom property option], and I set up my cell update binding there. Then, I scripted the data update in this way:
# On the chart's parent's propertyChange event handler
# If the data changes in some way...
if event.propertyName == 'data':
# Get the data from the container's custom data property
data = event.source.data
# Get the chart component
chart = event.source.getComponent('Box and Whisker Chart')
# Wipe the chart's dataset, and replace it to trigger an update
chart.data = system.dataset.toDataSet(['empty'], [])
chart.data = data
It's not the most intuitive approach, but it will work until you come up with something better.