"X12" Test On Seasonality
Usage
seasonality_combined(data, period, firstperiod = cycle(data)[1], mul = TRUE)
Arguments
- data
the input data.
- period
Tested periodicity.
- firstperiod
Position in a cycle of the first obs. For example, for a monthly,
firstperiod = 1
means January. Ifdata
is not a"ts"
object,firstperiod = 1
by default.- mul
boolean indicating if the seasonal decomposition is multiplicative (
mul = TRUE
) or additive (mul = FALSE
).
Details
Combined test on the presence of identifiable seasonality (see Ladiray and Quenneville, 1999).
Examples
seasonality_combined(ABS$X0.2.09.10.M, 12)
#> $seasonality
#> [1] "NONE"
#>
#> $kruskalwallis
#> Value: 96.33197
#> P-Value: 0.0000
#>
#> $stable
#> $stable$SSM
#> [1] 38848329
#>
#> $stable$dfM
#> [1] 11
#>
#> $stable$SSR
#> [1] 55472873
#>
#> $stable$dfR
#> [1] 413
#>
#> $stable$test
#> Value: 26.29354
#> P-Value: 0.0000
#>
#>
#> $evolutive
#> $evolutive$SSM
#> [1] 46387400
#>
#> $evolutive$dfM
#> [1] 33
#>
#> $evolutive$SSR
#> [1] 3398428
#>
#> $evolutive$dfR
#> [1] 363
#>
#> $evolutive$test
#> Value: 150.1463
#> P-Value: 0.0000
#>
#>
seasonality_combined(random_t(2, 1000), 7)
#> $seasonality
#> [1] "NONE"
#>
#> $kruskalwallis
#> Value: 3.694924
#> P-Value: 0.7179
#>
#> $stable
#> $stable$SSM
#> [1] 30.53799
#>
#> $stable$dfM
#> [1] 6
#>
#> $stable$SSR
#> [1] 7886.411
#>
#> $stable$dfR
#> [1] 993
#>
#> $stable$test
#> Value: 0.6408538
#> P-Value: 0.6976
#>
#>
#> $evolutive
#> $evolutive$SSM
#> [1] 929.3914
#>
#> $evolutive$dfM
#> [1] 141
#>
#> $evolutive$SSR
#> [1] 5164.218
#>
#> $evolutive$dfR
#> [1] 846
#>
#> $evolutive$test
#> Value: 1.079805
#> P-Value: 0.2635
#>
#>