If I have two different data sets that are in a time series, is there a simple way to find the correlation between the two sets in python?
For example with:
# [ (dateTimeObject, y, z) ... ]
x = [ (8:00am, 12, 8), (8:10am, 15, 10) .... ]
How might I get the correlation of y and z in Python?
Little slow on the uptake here. pandas (http://github.com/wesm/pandas and pandas.sourceforge.net) is probably your best bet. I’m biased because I wrote it but:
Notably if your data are over different sets of dates, it will compute the pairwise correlation. It will also automatically exclude NaN values!