CWCV               package:wavethresh               R Documentation

_C _W_a_v_e_l_e_t _C_r_o_s_s-_v_a_l_i_d_a_t_i_o_n

_D_e_s_c_r_i_p_t_i_o_n:

     Two-fold wavelet shrinkage cross-validation (in C)

_U_s_a_g_e:

     CWCV(ynoise, ll, x = 1:length(ynoise), filter.number = 10, family = 
             "DaubLeAsymm", thresh.type = "soft", tol = 0.01, verbose = 0, 
             plot.it = TRUE, interptype = "normal")

_A_r_g_u_m_e_n_t_s:

  ynoise: A vector of dyadic (power of two) length that contains the
          noisy data that you wish to apply wavelet shrinkage by
          cross-validation to.

      ll: The primary resolution that you wish to assume. No wavelet
          coefficients that are on coarser scales than ll will be
          thresholded.

       x: This function is capable of producing informative plots. It
          can be useful to supply the x values corresponding to the
          ynoise values. Further this argument is returned by this
          function which can be useful for later processors.

filter.number: This selects the smoothness of wavelet that you want to
          perform wavelet shrinkage by cross-validation.

  family: specifies the family of wavelets that you want to use. The
          options are "DaubExPhase" and "DaubLeAsymm".

thresh.type : this option specifies the thresholding type which can be
          "hard" or "soft".

     tol: this specifies the convergence tolerance for the
          cross-validation optimization routine (a golden section
          search).

 verbose: Controls the printing of "informative" messages whilst the
          computations progress. Such messages are generally annoying
          so it is turned off by default

 plot.it: If this is TRUE then plots of the universal threshold (used
          to obtain an upper bound on the cross-validation threshold)
          reconstruction and the resulting cross-validation estimate
          are produced.

interptype: Can take two values noise or normal. This option controls
          how cross-validation compares the estimate formed by leaving
          out the data with the "left-out" data. If interptype="noise"
          then two noisy values are averaged to compare with the
          estimated curve in between, otherwise if interptype="normal"
          then the curve estimate is averaged either side of a noisy
          left-out point.

_D_e_t_a_i_l_s:

     Compute the two-fold cross-validated wavelet shrunk estimate given
     the noisy data ynoise according to the description given in Nason,
     1996. 

     You must specify a primary resolution given by 'll'. This must be
     specified individually on each data set and can itself be
     estimated using cross-validation (although I haven't written the
     code to do this). 

     *Note*. The two-fold cross-validation method performs very badly
     if the input data is correlated. In this case I would advise using
     the methods proposed in Donoho and Johnstone, 1995 or Johnstone
     and Silverman, 1997 which can be carried out in WaveThresh using
     the 'threshold' function using the 'policy="sure"' option.

_V_a_l_u_e:

     A list with the following components 

       x: This is just the x that was input. It gets passed through
          more or less for convenience for the user.

  ynoise: A copy of the input ynoise noisy data.

    xvwr: The cross-validated wavelet shrunk estimate.

  yuvtwr: The universal thresholded version (note this is merely a
          starting point for the cross-validation algorithm. It should
          not be ta    ken seriously as an estimate. In particular its
          estimate of variance is likely to be inflated.) 

xvthresh: The cross-validated threshold

   xvdof: The number of non-zero coefficients in the cross-validated
          shrunk wavelet object (which is not returned).

   uvdof: The number of non-zero coefficients in the universal
          threshold shrunk wavelet object (which also is not returned)

   xkeep: always returns NULL!

   fkeep: always returns NULL!

_R_E_L_E_A_S_E:

     Version 3.0 Copyright Guy Nason 1994

_N_o_t_e:

     Plots of the universal and cross-validated shrunk estimates might
     be plotted if 'plot.it=TRUE.'

_S_e_e _A_l_s_o:

     'threshold'. 'threshold.wd'.

_E_x_a_m_p_l_e_s:

     #
     # This function is best used via the policy="cv" option in
     # the threshold.wd function.
     # See examples there.
     #

