In [2]:
%pylab inline
import pylab as py


Populating the interactive namespace from numpy and matplotlib

In [3]:
fname="2015-08-27_FlipFlop1.txt"

f1=file(fname)

filetext=f1.readlines()

data=[]
for i in range(12,len(filetext)):
    data.append(map(float, filetext[i].split()))
import pylab as py

d1=py.transpose(data)

In [12]:
ts=5000.0 #points/second
stt=1.5
end=2
Nosc=3

fig1=py.figure(figsize=(20,6))
ax1=fig1.add_subplot(111)
d2=d1[:,stt*ts:end*ts]
for i in range(3):
    chan=2*i+1
    ax1.plot(d2[0], d2[chan], "-", label=chan)
ax1.legend()
py.show()



In [14]:
fig2=py.figure(figsize=(6*Nosc,6))
cols=["blue","green","red"]
Nosc=3
for i in range(Nosc):
    c1=2*i+2
    c2=2*i+1
    subnum="1{}{}".format(Nosc,i+1)
    ax2=fig2.add_subplot(subnum)
    #ax2.text(-1,4,i)
    ax2.plot(d2[c1],d2[c2],color=cols[i])
    #ax2.axis([-1.5,1.0,-1,5])
py.show()



In [ ]: