Commits

Chris Lee-Messer  committed fd63040

commit before using with divya's data

  • Participants
  • Parent commits 42fd040

Comments (0)

Files changed (2)

File examples/chirp2.py

 #?signal.chirp
 N = 1000
 t=linspace(0,10,num=N) # implies fs=1000/10 = 100
+fs = 100
 ch = signal.chirp(t,1.0,6.0,20.0)
 
 stockwell.plots.stspecgram(ch, 100,t0=0,t1=10.0)
 title('chirp spectrum using the stockwell transform')
 
+# figure()
+# print "same signal but now focusing on 5-20Hz"
+# stockwell.plots.stspecgram(ch, 100, lofreq=5,hifreq=20, t0=0,t1=10)
+
+#
 figure()
-print "same signal but now focusing on 5-20Hz"
-stockwell.plots.stspecgram(ch, 100, lofreq=5,hifreq=20, t0=0,t1=10)
+specgram(ch, Fs=fs)

File stockwell/plots.py

     >>> r=plots.plotspec(psx,200)
     >>> # pylab.show() # to visualize this
     """
-    extent = [0,psx.shape[1], 0.0, fs/2.0] # default extents
+    extent = [0,psx.shape[1]/float(fs), 0.0, fs/2.0] # default extents
     if t0 != None and t1 != None:
         extent[0] = t0
         extent[1] = t1