def get_QT_interval(self, fig, ax, ax1, ax2, line2, qt_average_waveform, qt_all_spikes):
"""
This function allows the user to select the QT interval for a region of data.
input:
fig(plt.fig)
ax, ax1, ax2(plt.fig.subplot)
line2(plt.fig.subplot.plot([float]))
qt_average_waveform([float])
qt_all_spikes([MCS_Spike])
"""
ax.set_title(self.title)
ax.plot(qt_average_waveform)
for spike in qt_all_spikes:
ax1.plot(spike.voltage_data)
span = SpanSelector(ax, self.onselect, 'horizontal', useblit=True,
rectprops=dict(alpha=0.5, facecolor='red'))
plt.show(block=False)
a = raw_input("Press any key... ")
qt_start_point = self.indmin
qt_end_point = self.indmax
return qt_start_point, qt_end_point
评论列表
文章目录