Type: | Package |
Title: | Computing Lower Bound of Ljung-Box Test |
Version: | 2.0 |
Date: | 2023-06-09 |
Description: | The Ljung-Box test is one of the most important tests for time series diagnostics and model selection. The Hassani SACF (Sum of the Sample Autocorrelation Function) Theorem , however, indicates that the sum of sample autocorrelation function is always fix for any stationary time series with arbitrary length. This package confirms for sensitivity of the Ljung-Box test to the number of lags involved in the test and therefore it should be used with extra caution. The Hassani SACF Theorem has been described in : Hassani, Yeganegi and M. R. (2019) <doi:10.1016/j.physa.2018.12.028>. |
License: | GPL-3 |
Author: | Hossein Hassani [aut], Masoud Yarmohammdi [aut], Mohammad Reza Yeganegi [aut], Leila Marvian Mashhad [aut, cre] |
Maintainer: | Leila Marvian Mashhad <Leila.marveian@gmail.com> |
NeedsCompilation: | no |
Packaged: | 2023-06-09 10:01:51 UTC; ne_da |
Repository: | CRAN |
Date/Publication: | 2023-06-12 13:00:02 UTC |
Computing Lower Bound of Ljung-Box Test
Description
Because of the sensitivity of the Ljung-Box test to the number of lags involved in the test, this function computes lower bound of this test and draws it's plot.
Usage
Q_H(simnum = 10000, TT = 50)
Arguments
simnum |
number of simulation iterations. |
TT |
length of time serie. |
Value
Lower bound of the Ljung-Box test and it's plot.
Author(s)
Hossein hassani, Masoud yarmohammdi, Mohammad reza yeganegi and Leila Marvian Mashhad.
References
Hassani, H., & Yeganegi, M. R. (2019). "Sum of squared ACF and the Ljung-Box statistics." Physica A: Statistical Mechanics and Its Applications, 520, 81-86.
See Also
Box.test
Examples
Q_H(simnum = 10000, TT = 100)
Computing Sum of the Sample Autocorrelation Function
Description
The sum of the sample autocorrelation function, found in many standard time series textbooks and software, at lag h is considered. It is shown that this sum is always minus half for any stationary time series with arbitrary length L.
Usage
SACF(x)
Arguments
x |
it is stationary time series. |
Value
A number. It computes SACF.
Author(s)
Hossein hassani, Masoud yarmohammdi, Mohammad reza yeganegi and Leila Marvian Mashhad.
References
A note on the sum of the sample autocorrelation function Hossein Hassani Statistics Group, Cardiff School of Mathematics, Cardiff University, CF24 4AG, UK 2-Statistical Research and Training Center, Tehran, 1413717911, Iran
See Also
Box.test
Examples
x = rnorm(50,mean = 0,sd = 1)
SACF(x)