Folks,
I need to compute some cross-correlations between time series, and I naturally 
started to use numpy.correlate. Howver, I'm not sure about the convention 
being used:
The crosscorrelation is usually defined as 
$\gamma_{xy}[k]  = \sum_{i}{x[i] y[i+k]}$
So, when I compute
>>> numpy.dot(x[:-1],y[1:])
on two 1D series of same size $n$, I should have $\gamma[1]$.
With numpy.correlate, I have to use 
>>>numpy.correlate(x,y,'full')[(n-1)-1]
or reverse x and y to get $\gamma[1]$
Is that correct ? 
P.

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Numpy-discussion mailing list
Numpy-discussion@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/numpy-discussion

Reply via email to