hypersecant               package:VGAM               R Documentation

_H_y_p_e_r_b_o_l_i_c _S_e_c_a_n_t _D_i_s_t_r_i_b_u_t_i_o_n _F_a_m_i_l_y _F_u_n_c_t_i_o_n

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

     Estimation of the parameter of the hyperbolic secant distribution.

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

     hypersecant(link.theta="elogit", earg=if(link.theta=="elogit")
         list(min=-pi/2, max=pi/2) else list(), init.theta=NULL)
     hypersecant.1(link.theta="elogit", earg=if(link.theta=="elogit")
         list(min=-pi/2, max=pi/2) else list(), init.theta=NULL)

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

link.theta: Parameter link function applied to the parameter theta. See
          'Links' for more choices.

    earg: List. Extra argument for the link. See 'earg' in 'Links' for
          general information.

init.theta: Optional initial value for theta. If failure to converge
          occurs, try some other value. The default means an initial
          value is determined internally.

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

     The probability density function of the hyperbolic secant
     distribution is given by

      f(y) =exp(theta*y + log(cos(theta ))) / (2*cosh(pi*y/2)),

     for parameter pi/2 < theta < pi/2 and all real y. The mean of Y is
     tan(theta) (returned as the fitted values).

     Another parameterization is used for 'hypersecant.1()'. This uses

 f(y) =(cos(theta)/pi) * y^(-0.5+theta/pi) * (1-y)^(-0.5-theta/pi),

     for parameter pi/2 < theta < pi/2 and 0 < y < 1. Then the mean of
     Y is 0.5 + theta/pi (returned as the fitted values) and the
     variance is (pi^2 - 4*theta^2) / (8*pi^2).

     For both parameterizations Newton-Raphson is same as Fisher
     scoring.

_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'.

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

     T. W. Yee

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

     Jorgensen, B. (1997) _The Theory of Dispersion Models_. London:
     Chapman & Hall.

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

     'elogit'.

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

     x = rnorm(n <- 200)
     y = rnorm(n)  # Not very good data!
     fit = vglm(y ~ x, hypersecant, trace=TRUE, crit="c")
     coef(fit, matrix=TRUE)
     fit@misc$earg

     # Not recommended
     fit = vglm(y ~ x, hypersecant(link="identity"), trace=TRUE, crit="c")
     coef(fit, matrix=TRUE)
     fit@misc$earg

