recnormal1               package:VGAM               R Documentation

_U_p_p_e_r _R_e_c_o_r_d _V_a_l_u_e_s _f_r_o_m _a _U_n_i_v_a_r_i_a_t_e _N_o_r_m_a_l _D_i_s_t_r_i_b_u_t_i_o_n

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

     Maximum likelihood estimation of the two parameters of a
     univariate normal distribution when the observations are upper 
     record values.

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

     recnormal1(lmean="identity", lsd="loge",
                imean=NULL, isd=NULL, method.init=1, zero=NULL)

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

lmean, lsd: Link functions applied to the mean and sd parameters. See
          'Links' for more choices.

imean, isd: Numeric. Optional initial values for the mean and sd. The
          default value 'NULL' means they are computed internally, with
          the help of 'method.init'.

method.init: Integer, either 1 or 2 or 3. Initial method, three
          algorithms are implemented. Choose the another value if
          convergence fails, or use 'imean' and/or 'isd'.

    zero: An integer vector, containing the value 1 or 2. If so, the
          mean or standard deviation respectively are modelled as an
          intercept only. Usually, setting 'zero=2' will be used, if
          used at all. The default value 'NULL' means both
          linear/additive predictors are modelled as functions of the
          explanatory variables.

_D_e_t_a_i_l_s:

     The response must be a vector or one-column matrix with strictly
     increasing values.

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

     An object of class '"vglmff"' (see 'vglmff-class'). The object is
     used by modelling functions such as 'vglm', and 'vgam'.

_N_o_t_e:

     This family function tries to solve a difficult problem, and the
     larger the data set the better. Convergence failure can commonly
     occur, and  convergence may be very slow, so set 'maxit=200,
     trace=TRUE', say. Inputting good initial values are advised.

     This family function uses the BFGS quasi-Newton update formula for
     the working weight matrices.  Consequently the estimated
     variance-covariance matrix may be inaccurate or simply wrong! The
     standard errors must be therefore treated with caution; these are
     computed in functions such as 'vcov()' and 'summary()'.

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

     T. W. Yee

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

     Arnold, B. C. and Balakrishnan, N. and Nagaraja, H. N. (1998)
     _Records_, New York: John Wiley & Sons.

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

     'normal1', 'dcnormal1'.

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

     n = 10000
     mymean = 100
     # First value is reference value or trivial record
     rawy = c(mymean, rnorm(n, me=mymean, sd=16))

     # Keep only observations that are records
     delete = c(FALSE, rep(TRUE, len=n))
     for(i in 2:length(rawy))
         if(rawy[i] > max(rawy[1:(i-1)])) delete[i] = FALSE
     (y = rawy[!delete])

     fit = vglm(y ~ 1, recnormal1, trace=TRUE, maxit=200)
     coef(fit, matrix=TRUE)
     Coef(fit)
     summary(fit)

