Learn R Programming

TSdisaggregation (version 2.0.0)

TempDisaggDGP: High and Low-Frequency Data Generating Processes

Description

This function generates the high-frequency \(n \times 1\) response vector \(y\), according to \(y=X\beta+\epsilon\), where \(X\) is an \(n\times p\) matrix of indicator series, and the \(p\times 1\) coefficient vector may be sparse. The low-frequency \(n_l\times 1\) vector \(Y\) can be generated by pre-multiplying an aggregation matrix \(n_l\times n\) matrix, such that the sum, the average, the last or the first value of \(y\) equates the corresponding \(Y\) observation. The parameter aggRatio is the specified aggregation ratio between the low and high frequency series, e.g. aggRatio = 4 for annual-to-quarterly and aggRatio = 3 for quarterly-to-monthly. If \(n > aggRatio \times n_l\), then the last \(n - aggRatio \times n_l\) columns of the aggregation matrix are 0 such that \(Y\) is only observed up to \(n_l\). For a comprehensive review, see dagum2006benchmarking;textualTSdisaggregation.

Usage

TempDisaggDGP(
  n_l,
  n,
  aggRatio = 4,
  p = 1,
  beta = 1,
  sparsity = 1,
  method = "Chow-Lin",
  aggMat = "sum",
  rho = 0,
  mean_X = 0,
  sd_X = 1,
  sd_e = 1,
  simul = FALSE,
  setSeed = 42
)

Arguments

n_l

Size of the low frequency series.

n

Size of the high frequency series.

aggRatio

aggregation ratio (default is 4)

p

The number of high-frequency indicator series to include.

beta

The positive and negative beta elements for the coefficient vector.

sparsity

Sparsity percentage of the coefficient vector.

method

DGP of residuals, either 'Denton', 'Denton-Cholette', 'Chow-Lin', 'Fernandez', 'Litterman'.

aggMat

Aggregation matrix according to 'first', 'sum', 'average', 'last'.

rho

The residual autocorrelation coefficient. Default is 0.

mean_X

Mean of the design matrix. Default is 0.

sd_X

Standard deviation of the design matrix. Default is 1.

sd_e

Standard deviation of the errors. Default is 1.

simul

When 'TRUE' the design matrix and the coefficient vector are fixed.

setSeed

The seed used when 'simul' is set to 'TRUE'.

Value

y_Gen Generated high-frequency response series.

Y_Gen Generated low-frequency response series.

X_Gen Generated high-frequency indicator series.

Beta_Gen Generated coefficient vector.

e_Gen Generated high-frequency residual series.

References

Examples

Run this code
# NOT RUN {
data = TempDisaggDGP(n_l=25, n=100, aggRatio=4,p=10, rho=0.5)
X = data$X_Gen
Y = data$Y_Gen
# }

Run the code above in your browser using DataLab