Clearing Chart Markers in Script

I am using a script on a chart that marks values over a certain limit, using the jfree ValueMarker, each time the chart’s data changes (it is linked to “property change”). However, each time the script triggers it re-writes all of the markers, on top of the old markers; this causes the markers and their labels to become bold and fuzzy.

Is there a command or method I can use to clear all previous markers each time the script runs?

You need to clearRangeMarkers/clearDomainMarkers as appropriate from the XYPlot: http://www.jfree.org/jfreechart/api/javadoc/org/jfree/chart/plot/XYPlot.html#clearDomainMarkers--

Thank you, I was having trouble finding the exact command.