Interface around 'JDemetra+' (< https://github.com/jdemetra/jdemetra-app>), the seasonal adjustment software officially recommended to the members of the European Statistical System (ESS) and the European System of Central Banks. It offers full access to all options and outputs of 'JDemetra+', including the two leading seasonal adjustment methods TRAMO/SEATS+ and X-12ARIMA/X-13ARIMA-SEATS.
RJDemetra is a R interface to JDemetra+, the seasonal adjustment software officially recommended to the members of the European Statistical System (ESS) and the European System of Central Banks. JDemetra+ implements the two leading seasonal adjustment methods TRAMO/SEATS+ and X-12ARIMA/X-13ARIMA-SEATS.
Besides seasonal adjustment, JDemetra+ bundles other time series models that are useful in the production or analysis of economic statistics, including for instance outlier detection, nowcasting, temporal disaggregation or benchmarking.
For more details on the JDemetra+ software see https://github.com/jdemetra/jdemetra-app.
RJDemetra offers full access to all options and outputs of JDemetra+.
RJDemetra relies on the rJava package and Java SE 8 or later version is required.
# Install release version from CRANinstall.packages("RJDemetra")# Install development version from GitHub# install.packages("devtools")devtools::install_github("jdemetra/rjdemetra")
To seasonally adjust a time series with a pre-defined specification you
can either use the x13_def()
function for the X-13ARIMA method or the
tramoseats_def()
function for the TRAMO-SEATS method.
library(RJDemetra)myseries <- ipi_c_eu[, "FR"]x13_model <- x13_def(myseries) # X-13ARIMA methodts_model <- tramoseats_def(myseries) # TRAMO-SEATS method# Basic plot with the original series, the trend and the SA seriesplot(x13_model, type_chart = "sa-trend")
# S-I ratioplot(x13_model$decomposition)
x13_spec
instead of x13_spec_def
, x13
instead of x13_def
, tramoseats_spec
instead of tramoseats_spec_def
, tramoseats
instead of tramoseats_def
, regarima_spec_tramoseats
instead of regarima_spec_def_tramoseats
, regarima_tramoseats
instead of regarima_def_tramoseats
, regarima_x13
instead of regarima_def_x13
and regarima_spec_x13
instead of regarima_spec_def_x13
.object
argument renamed by spec
in x13_spec
, tramoseats_spec
, regarima_spec_x13
and regarima_spec_tramoseats
.preliminary.check
added to the specifications functions (regarima_spec_tramoseats
, tramoseats_spec
, regarima_spec_x13
and x13_spec
). By default (preliminary.check = TRUE
), JDemetra+ checks the quality of the input series and exclude highly problematic ones: e.g. these with a number of identical observations and/or missing values above pre-specified threshold values. When preliminary.check = FALSE
, the thresholds are ignored and process is performed, when possible. (issue #39)tradingdays.option = "UserDefined
and add new regressors variables (usrdef.varEnabled = TRUE
to enable user-defined regressors and usrdef.var
to define the regressors) using usrdef.varType = "Calendar"
.usrdef.varType
argument is recycled with the number of variables defined in the usrdef.var
parameter.jx13
, jtramoseats
, jregarima
, jregarima_x13
, jregarima_tramoseats
and get_jmodel
. Therefore, there is no formatting and the computation is faster than the non 'j' functions (x13
, tramoseats
, regarima
, regarima_x13
, regarima_tramoseats
and get_model
). To manipulate these objects, there are three functions: get_dictionary
to get the indicators that can be extracted, get_indicators
to extract these indicators and jSA2R
to get the formatted R model.x11.fcast
can now be set to 0 or 1 (issue #42)