Meaning of a lag in time-series and autocorrelation

7 views (last 30 days)
Hi everyone,
I know this might be a very naive question, but I am very new to time series analysis and all of a sudden I have been forced to understand a lot of unfamilair stuff
My first question is "what is the meaning of a lag (how do you define) in time-series data?"
My second question is,
I have a series of data like below
time(femtoseconds) distance (Angstrom)
0 15.769
100 16.160
200 15.571
300 15.816
400 15.702
...... ......
...... ......
49990 15.907
I want to find the time at which the distance data is NOT correlated to itself (I guess that is what they call as data being "stationary"). Could anyone of you please tell me how to find that point in time using Matlab?
Thank you very much
Sajeewa Dewage

Answers (1)

Image Analyst
Image Analyst on 18 May 2013
I guess you'd call xcorr() and plot it and see when the plot "levels out". Did you try that?
  3 Comments
Image Analyst
Image Analyst on 18 May 2013
Of course it's going to be twice as long. That's what you expect. If you don't know why, then review how correlation works. If it looks like an isosceles triangle, then your data is just uniform, because the correlation of a box with a box is a triangle.
Malcolm Lidierth
Malcolm Lidierth on 18 May 2013
This is what you might expect. The correlation at lag=0 is always perfect [the correlation of x(t) vs x(t)]. Try using the 'coeff' option in xcorr.

Sign in to comment.

Community Treasure Hunt

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

Start Hunting!