Commits

clee  committed a83c2b1

working on better display

  • Participants
  • Parent commits 0501eee

Comments (0)

Files changed (4)

 a C compiler (tested with gcc so far)
 numpy (tested with 1.3)
 
+ * note: I am working on getting this to work on windows at some point but it does not work currently -clm 11/2010
 
 see also
 Code from Dr. Stockwell's web site for the stockwell transform

File examples/chirp.py

 #?signal.chirp
 t=linspace(0,10,num=1000)
 ch = signal.chirp(t,1.0,6.0,20.0)
-figure()
-plot(t,ch)
+#figure()
+#plot(t,ch)
 K=4; N=len(t)
 tapers = smt.calc_tapers(K,N)
 chs = smt.mtst(K,tapers, ch, 0,len(ch)/2)
 chtapers = smt.calc_tapers(K,len(ch))
 chs = smt.mtst(K,chtapers, ch, 0,len(ch)/2)
-figure(); imshow(chs); axis('auto')
-figure(); subplot(211); plot(ch); subplot(212); imshow(chs); axis('auto')
+
+# these don't quite look right
+#figure(); imshow(chs); axis('auto')
+#figure(); subplot(211); plot(ch); subplot(212); imshow(chs); axis('auto')
 ## now try a longer signal
+
+import stockwell.plot as stplot
+
+print "powerstack of multitaper version of signal"
+stplot.stpowerstack(ch, chs)

File stockwell/__init__.py

 	array
 	"""
 	return row*srate/length
+
+# utilites/display functions in plot

File stockwell/stmodule.c

 static char Doc_st[] =
 "st(x[, lo, hi]) returns the 2d, complex Stockwell transform of the real\n\
 array x. If lo and hi are specified, only those frequencies (rows) are\n\
-returned; lo and hi default to 0 and n/2, resp., where n is the length of x.";
+returned; lo and hi default to 0 and n/2, resp., where n is the length of x.\n\
+\n\
+Details:\n\
+This usees PyArray_ContiguousFromObject to make a potential copy of x and\n\
+returns as the result a new (PyArrayObject *)PyArray_SimpleNew(2, dim, PyArray_CDOUBLE)\n\
+dim[0]=hi-lo+1, dim[1] = n";
 
 static PyObject *st_wrap(PyObject *self, PyObject *args)
 {