This commit is contained in:
tillraab 2019-10-01 15:54:40 +02:00
parent 56c2802b47
commit ccf1e1bb0b

View File

@ -360,10 +360,10 @@ def main():
if init_fig == True:
yspan = (np.min(channel_data[power_channel]), np.max(channel_data[power_channel]))
ylim = (yspan[0] / 1000 - np.abs(np.diff(yspan)) / 1000 * 0.2, yspan[1] / 1000 + np.abs(np.diff(yspan)) / 1000 * 0.2)
ylim = (yspan[0] - np.abs(np.diff(yspan)) * 0.2, yspan[1] + np.abs(np.diff(yspan))* 0.2)
for ch in channel_array:
h, = Plot.axs[ch].plot(np.arange(250)[:len(channel_data[ch])] / rate, np.array(channel_data[ch]) / 1000 , color='k')
h, = Plot.axs[ch].plot(np.arange(250)[:len(channel_data[ch])] / rate, np.array(channel_data[ch]), color='k')
Plot.axs[ch].set_ylim(ylim)
Plot.channel_handle.append(h)
@ -374,7 +374,7 @@ def main():
yspan = [np.min(channel_data[power_channel]), np.max(channel_data[power_channel])]
ylim = [yspan[0] - np.abs(np.diff(yspan)) * 0.2, yspan[1] + np.abs(np.diff(yspan)) * 0.2]
for ch in channel_array:
Plot.channel_handle[ch].set_data(np.arange(250)[:len(channel_data[ch])] / rate, np.array(channel_data[ch]) / 1000)
Plot.channel_handle[ch].set_data(np.arange(250)[:len(channel_data[ch])] / rate, np.array(channel_data[ch]))
Plot.axs[ch].set_ylim(ylim)
Plot.fig.canvas.draw()