frun                package:ftnonpar                R Documentation

_R_u_n_s _a_n_d _l_o_c_a_l _e_x_t_r_e_m_e_s

_D_e_s_c_r_i_p_t_i_o_n:

     Calculation of bounds for functions such that the residuals
     satisfy a run criterion

_U_s_a_g_e:

     frun(y, ..., alpha = 0.5, r = 0, mr = 0)

_A_r_g_u_m_e_n_t_s:

       y: the data

     ...: an optional argument which specifies the approximate
          positions of the local extreme values.  These should be
          consisten with the run length otherwise  the result will be
          nonsensical. Should you wish to use this option then you
          should first run the macro without it. The item xb of the
          output list gives  the acceptable limits of the local extreme
          values. You can then specify the positions within these
          limits.

   alpha: Quantile determining the acceptable run length.

       r: Acceptable run length: Overrides alpha if not 0

      mr: mr=0 minimizes the run length consistent with the number of
          local extreme values found for the specified  run length.
          mr=1 disables the option.

_V_a_l_u_e:

  l1    : lower bounds

  u1    : upper bounds

  l2    : lower bound with specified extremes: the default choices for
          the positions of the local extreme values are the mid-points
          of the intervals specified by xb above.

  u2    : upper bound with specified extremes

  f     : function between l2 and u2 satisfying run condition

  xb    : bounds for location of extremes: the position of the ith
          extreme value lies between xb[2*i-1] and xb[2*i]

  nx    : number of extremes

  r     : run length: may differ from specified if mr=1

_N_o_t_e:

     IN GENERAL THE MEAN OF THE BOUNDS l2 AND u2 (l2+u2)/2 GIVES A
     BETTER REGRESSION FUNCTION THAN f. HOWEVER THIS FUNCTION IS
     INFINITE AT THE TWO ENDPOINTS AND AT LOCAL EXTREME VALUES. IN
     THESE INTERVALS IT CAN BE REPLACED BY ANY VALUES WHICH DO NOT
     ALTER THE NUMBER OF LOCAL EXTREME VALUES. THE MEDIAN OF THE
     y-VALUES IN THESE INTERVALS IS A REASONABLE  CHOICE.

_A_u_t_h_o_r(_s):

     Laurie Davies Laurie.Davies@uni-essen.de

_R_e_f_e_r_e_n_c_e_s:

     Davies, P. L. (1995) Data features. Statistica Neerlandica
     49,185-245.

     Davies, P. L. and Kovac, A. (2001) Local Extremes, Runs, Strings
     and Multiresolution (with discussion) Annals of Statistics. 29.
     p1-65

_S_e_e _A_l_s_o:

     'mintvmon','pmreg','l1pmreg'

_E_x_a_m_p_l_e_s:

