I'm using a dynamic line chart from Canvas.js to render an ECG (heart beat) signal and I also came up with a peak detection algorithm but I need to know when exactly a peak is rendered so I can trigger a beeping sound. Sets of points are inserted in the chart's points array as they come through a websocket so I have no control over single points rendering.
Any suggestions would be appreciated, thanks!