Is there a way to add a new mark to a Plot after it has been created?
More broadly, I have a few lines I want to display, but only one of the lines (call this the prediction line) will be displayed when the pointer moves across the chart. I want to be able to only display the prediction line to the right of pointerX
.
I imagine one option will be to use the input EventListener to feed into a callback that can dynamically filter what should be displayed for the prediction line, but this would require being able to also append a Plot.line
mark in the callback.
I hope this is clear! Any help is much appreciated, thanks in advance!