-
Notifications
You must be signed in to change notification settings - Fork 318
Closed
Description
The following chunk in https://github.com/MIT-LCP/wfdb-python/blob/master/demo.ipynb fails with a TypeError.
# Demo 7 - Read the multi-segment record and plot waveforms from the MIMIC matched waveform database.
# Notice that some channels have no valid values to plot
record = wfdb.rdrecord('sample-data/multi-segment/s00001/s00001-2896-10-10-00-31',
sampfrom=3000000, sampto=4000000)
wfdb.plot_wfdb(record, title='Record s00001/s00001-2896-10-10-00-31')
display(record.__dict__)
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-10-46517ed3fe63> in <module>
3 record = wfdb.rdrecord('sample-data/multi-segment/s00001/s00001-2896-10-10-00-31',
4 sampfrom=3000000, sampto=4000000)
----> 5 wfdb.plot_wfdb(record, title='Record s00001/s00001-2896-10-10-00-31')
6 display(record.__dict__)
7
~/projects/wfdb-python/wfdb/plot/plot.py in plot_wfdb(record, annotation, plot_sym, time_units, title, sig_style, ann_style, ecg_grids, figsize, return_fig)
405 ylabel, record_name) = get_wfdb_plot_items(record=record,
406 annotation=annotation,
--> 407 plot_sym=plot_sym)
408
409 return plot_items(signal=signal, ann_samp=ann_samp, ann_sym=ann_sym, fs=fs,
~/projects/wfdb-python/wfdb/plot/plot.py in get_wfdb_plot_items(record, annotation, plot_sym)
432 sig_units = record.units
433 record_name = 'Record: %s' % record.record_name
--> 434 ylabel = ['/'.join(pair) for pair in zip(sig_name, sig_units)]
435 else:
436 signal = fs = ylabel = record_name = None
~/projects/wfdb-python/wfdb/plot/plot.py in <listcomp>(.0)
432 sig_units = record.units
433 record_name = 'Record: %s' % record.record_name
--> 434 ylabel = ['/'.join(pair) for pair in zip(sig_name, sig_units)]
435 else:
436 signal = fs = ylabel = record_name = None
TypeError: sequence item 1: expected str instance, NoneType found
Metadata
Metadata
Assignees
Labels
No labels