[SciPy-user] moving average, moving standard deviation, etc...
Stefan van der Walt
stefan at sun.ac.za
Sun Dec 24 14:01:50 EST 2006
Hi Matt
On Sun, Dec 24, 2006 at 04:23:08PM +0000, Matt Knox wrote:
> Ok, thanks. So it sounds like there is no easy way to do this generally without
> doing some looping in python (for the standard deviation anyway), or writing
> some C code. I'm more interested in the general strategy for doing these kinds
> of calculations than these specific examples themselves necessarily. Although
> they are useful for making pretty charts sometimes.
Like someone mentioned earlier, you can do averaging using
numpy.convolve. For the rest, C code may be the easiest option -- and
with ctypes it's a breeze.
Take a look at Albert's page,
http://www.scipy.org/Cookbook/Ctypes2
and let me know if you need further examples.
Cheers
Stéfan
More information about the SciPy-User
mailing list