Learn R Programming

cxreg (version 1.0.0)

dft.X: Discrete Fourier Transform of matrix X

Description

Computes the (normalized) discrete Fourier transform (DFT) of a matrix X row-wise using mvfft, and extracts a window of frequencies centered at a target index.

Usage

dft.X(X, j, m)

Value

A complex-valued matrix of dimension (2m + 1) × nvar representing selected DFT components of the original matrix.

Arguments

X

A numeric matrix of size \(nobs \times nvar\), where DFT is applied across the rows (time points).

j

An integer index in \(1,\ldots,nobs\) around which the frequency window is centered.

m

A non-negative integer specifying the window half-width. The function returns 2m + 1 DFT components centered around j.