Dear R list I am trying to understand the auto-correlation concept. Auto-correlation is the self-correlation of random variable X with a certain time lag of say t.
The article "http://www.mit.tut.fi/MIT-3010/luentokalvot/lk10-11/MDA_lecture16_11.pdf" (Page no. 9 and 10) gives the methodology as under. Suppose you have a time series observations as say X = c(44,41,46,49,49,50,40,44,49,41) # For autocorrelation with time lag of 1 we define A = c(41,46,49,49,50,40,44,49,41) # first element of X not considered B = c(44,41,46,49,49,50,40,44,49) # Last element of X not considered > cor(A,B) [1] -0.02581234 However, if I try the acf command using library tseries I get acf(X, 1) Autocorrelations of series âXâ, by lag     0     1  1.000 -0.019 So by usual correlation command (where same random variable X is converted into two series with a time lag of 1), I obtain auto-correlation as -0.02581234 and by acf command I get auto-correlation = -0.019 (for time lag of 1). I am not able to figure out where I am going wrong or is it my understanding of auto-correlation procedure is wrong? Will be grateful if someone guides . Vincy [[alternative HTML version deleted]]
______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.