Homogeneity test for discrete wavelet transform crystals.

USAGE:

wavVarianceHomogeneity( x, wavelet = "s8", n.levels = 1:4 )

DESCRIPTION:

Tests for homogeneity of variance for each scale of a discrete wavelet transform (DWT) decomposition. Based on the assumption that the DWT decorrelates colored noise processes, the interior wavelet coefficients in a given scale (dj) can be regarded as a zero mean Gaussian white noise process. For a homogeneous distribution of dj, there is an expected linear increase in the cumulative energy as a function of time. The so called D-statistic denotes the maximum deviation of the dj from a hypothetical linear cumulative energy trend. This D-statistic is then compared to a table of critical D-statistics that defines the distribution of D for various sample sizes. Comparing the D-statistic of dj to the corresponding critical values provides a means of quantitatively rejecting or accepting the linear cumulative energy hypothesis. This function performs this test for an ensemble of distribution probabilities.

REQUIRED ARGUMENTS:

x
An object of class dwt with convolution style filtering, a corresponding wavebound object, or a numeric vector. In the latter case, DWT parameters can be passed to specify the type of wavelet to use and the number of decomposition levels to perform.

OPTIONAL ARGUMENTS:

wavelet
A character string denoting the filter type. Valid only for input not of class dwt or wavebound. Default: ``s8".
n.levels
The number of decomposition levels. Valid only for input not of class dwt or wavebound. Default: the maximum decomposition level that contains at least one interior wavelet coefficient.
significance
A numeric vector of real values in the interval (0,1). Qualitatively the significance is the fraction of times that the linear cumulative energy hypothesis is incorrectly rejected. It is equal to the difference of the distribution probability (p) and unity. Default: c(0.1, 0.05, 0.01).
lookup
A logical flag for accessing precalculated critical D-statistics. The critical D-statistics are calculated for a variety of sample sizes and significances. If lookup is TRUE, this table is accessed. The table is stored as the matrix object D.table.critical and is loaded with S+Wavelets. Missing table values are calculated using the input arguments: n.realization, n.repetition and tolerance. Default: TRUE.
n.realization
An integer specifying the number of realizations to generate in a Monte Carlo simulation for calculating the D-statistic(s). This parameter is used either when lookup is FALSE, or when lookup is TRUE and the table is missing values corresponding to the specified significances. Default: 10000.
n.repetition
an integer specifying the number of Monte Carlo simulations to perform. This parameter is coordinated with the n.realization parameter. Default: 3.
tolerance
A numeric real scalar that specifies the amplitude threshold to use in estimating critical D-statistic(s) via the Inclan-Tiao approximation. Setting this parameter to a higher value results in a lesser number of summation terms at the expense of obtaining a less accurate approximation. Default: 1e-6.

VALUE:

result
An object of class WaveletHomogeneity.

DETAILS:

An Inclan-Tiao approximation of critical D-statistics is used for sample sizes N >= 128 while a Monte Carlo technique is used for N < 128. For the Monte Carlo technique, the D-statistic for a Gaussian white noise sequence of length N is calculated. This process is repeated n.realization times, forming a distribution of the D-statistic. The critical values corresponding to the significances are calculated a total of n.repetition times, and averaged to form an approximation to the D-statistic(s). Because the Monte Carlo study can be both computationally and memory intensive, it is highly recommended that lookup be set to TRUE, its default value.

REFERENCES:

(1) D. B. Percival and A. T. Walden, ``Wavelet Methods for Time Series Analysis'', Cambridge University Press, 2000.

SEE ALSO:

, , , .

EXAMPLES:

   ## perform a homogeneity of variance test for a DWT
   ## decomposition of a long memory process realization
   homogeneity <- wavVarianceHomogeneity( fdp045 )