From 7db6d0ede5051ef966bc7b7e34b62f4cfef13d3a Mon Sep 17 00:00:00 2001 From: Benjamin Moody Date: Thu, 17 Mar 2022 16:07:47 -0400 Subject: [PATCH] plot_annotation: show annotation markers atop signals. Display the annotation markers at a higher "z-order" than the signals, so that the markers are visible when they overlap with the signals. --- wfdb/plot/plot.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wfdb/plot/plot.py b/wfdb/plot/plot.py index 99279b53..68d7fac2 100644 --- a/wfdb/plot/plot.py +++ b/wfdb/plot/plot.py @@ -355,7 +355,8 @@ def plot_annotation(ann_samp, n_annot, ann_sym, signal, n_sig, fs, time_units, raise Exception('IndexError: try setting shift_samps=True in ' 'the "rdann" function?') - axes[ch].plot(ann_samp[ch] / downsample_factor, y, ann_style[ch]) + axes[ch].plot(ann_samp[ch] / downsample_factor, y, ann_style[ch], + zorder=4) # Plot the annotation symbols if any if ann_sym is not None and ann_sym[ch] is not None: