Effacer les filtres
Effacer les filtres

comparing two time series

15 vues (au cours des 30 derniers jours)
Oliver
Oliver le 28 Nov 2011
Commenté : Tom Hawkins le 7 Sep 2018
Hello, I'm using Matlab to compare two time series for rainfall across a year using two different methods of measurement. So I have two sets of data of hourly data for a year, and I was wondering what the best way to statistically compare them to see if the peaks are the same and so on, to compare this new method of rainfall measurment.
Many thanks,
Olly
  3 commentaires
Hin Kwan Wong
Hin Kwan Wong le 28 Nov 2011
I assume you do not know the true temperature? As Wayne suggested more info is welcome, such as which method is the more 'accurate' one.
Plot the two together on the same graph is the best you can do visually. If both method are good, scatter plot the two series should give you a nice highly correlated (approx. straight line) with positive slope
Numerically, off-diagonal elements of the normalized covariance matrix
cov(A/std(A),B/std(B)) will also give you an idea how 'close' the two measurements are. The closer the value to one, the more similar they are. The off diagonal element is basically the slope of the scatter plot mentioned earlier minus normalization factors.
Tom Hawkins
Tom Hawkins le 7 Sep 2018
This suggestion using the covariance matrix is very useful, but what happens if std(A) or std(B) is zero? For example, if we compare two signals that are both constant, but one might have an offset relative to the other, say. Can we replace the calculation with something that doesn't return NaN and is comparable with the covariance calculation?

Connectez-vous pour commenter.

Réponses (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by