Skip to contents

X-11 Decomposition Algorithm

Usage

x11(ts, spec = x11_spec(), userdefined = NULL)

Arguments

ts

an univariate time series.

spec

the specification.

userdefined

a vector containing additional output variables (see x13_dictionary()).

Examples

y <- rjd3toolkit::ABS$X0.2.09.10.M
x11_spec <- x11_spec()
x11(y, x11_spec)
#> Last values
#>                d1 d2 d4        d5       d6       d7        d8        d9
#> Mar 2017 1370.300 NA NA 0.8961795 1529.046 1549.437 0.8843860       NaN
#> Apr 2017 1508.745 NA NA 0.9370285 1610.138 1551.362 0.9814599 0.9725289
#> May 2017 1452.400 NA NA 0.9240579 1571.763 1552.613 0.9354553       NaN
#> Jun 2017 1557.200 NA NA 0.9906046 1571.969 1554.256 1.0018939       NaN
#> Jul 2017 1451.753 NA NA 0.9669725 1501.339 1554.036 0.9301585 0.9341824
#> Aug 2017 1303.100 NA NA 0.8370380 1556.799 1554.112 0.8384851       NaN
#>                d10      d11      d12       d13
#> Mar 2017 0.8911974 1537.594 1549.121 0.9925591
#> Apr 2017 0.9472835 1607.333 1550.650 1.0365542
#> May 2017 0.9277056 1565.583 1551.579 1.0090258
#> Jun 2017 0.9945226 1565.776 1552.914 1.0082826
#> Jul 2017 0.9598855 1505.909 1552.756 0.9698294
#> Aug 2017 0.8381839 1554.671 1552.438 1.0014382
x11_spec <- set_x11(x11_spec, henderson.filter = 13)
x11(y, x11_spec)
#> Last values
#>                d1 d2 d4        d5       d6       d7        d8        d9
#> Mar 2017 1370.300 NA NA 0.8957968 1529.700 1556.611 0.8803097       NaN
#> Apr 2017 1521.625 NA NA 0.9391175 1620.271 1562.636 0.9743791 0.9737554
#> May 2017 1452.400 NA NA 0.9239661 1571.919 1563.794 0.9287669       NaN
#> Jun 2017 1557.200 NA NA 0.9916495 1570.313 1560.504 0.9978827       NaN
#> Jul 2017 1453.790 NA NA 0.9669146 1503.535 1555.034 0.9295618 0.9348928
#> Aug 2017 1303.100 NA NA 0.8369658 1556.933 1547.539 0.8420469       NaN
#>                d10      d11      d12       d13
#> Mar 2017 0.8899565 1539.738 1556.256 0.9893865
#> Apr 2017 0.9498667 1602.962 1560.758 1.0270404
#> May 2017 0.9267578 1567.184 1560.959 1.0039883
#> Jun 2017 0.9952607 1564.615 1557.551 1.0045354
#> Jul 2017 0.9607704 1504.522 1552.689 0.9689783
#> Aug 2017 0.8393622 1552.488 1545.113 1.0047731