

rs2(gnlm)                                    R Documentation

_F_i_t _a _T_w_o_-_f_a_c_t_o_r _B_o_x_-_T_i_d_w_e_l_l _N_o_n_l_i_n_e_a_r _R_e_s_p_o_n_s_e _S_u_r_f_a_c_e

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

     `rs2' fits a two-covariate power-transformed response
     surface by iterating the function, `glm'.

_U_s_a_g_e_:

     rs2(y, x1, x2, power=c(1,1), weight=rep(1,length(y)), family=normal,
             iterlim=20)

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

       y: Response variable

      x1: First covariate

      x2: Second covariate

   power: Initial estimates of the two power transformations

  weight: Weight vector

  family: glm family

 iterlim: Iteration limit

_V_a_l_u_e_:

     A list of class, rs, is returned containing the model
     and the power estimates.

_A_u_t_h_o_r_(_s_)_:

     J.K. Lindsey

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

     `lm', `glm', `gnlr', `gnlr3', `fmr', `rs3'.

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

     x1 <- rep(1:4,5)
     x2 <- rep(1:5,rep(4,5))
     y <- rpois(20,1+2*sqrt(x1)+3*log(x2)+4*x1+log(x2)^2+2*sqrt(x1)*log(x2))
     rs2(y, x1, x2, family=poisson)

