InsectSprays            package:datasets            R Documentation

_E_f_f_e_c_t_i_v_e_n_e_s_s _o_f _I_n_s_e_c_t _S_p_r_a_y_s

_D_e_s_c_r_i_p_t_i_o_n:

     The counts of insects in agricultural experimental units treated
     with different insecticides.

_U_s_a_g_e:

     InsectSprays

_F_o_r_m_a_t:

     A data frame with 72 observations on 2 variables.

       [,1]  count  numeric  Insect count
       [,2]  spray  factor   The type of spray

_S_o_u_r_c_e:

     Beall, G., (1942) The Transformation of data from entomological
     field experiments, _Biometrika_, *29*, 243-262.

_R_e_f_e_r_e_n_c_e_s:

     McNeil, D. (1977) _Interactive Data Analysis_. New York: Wiley.

_E_x_a_m_p_l_e_s:

     require(stats)
     boxplot(count ~ spray, data = InsectSprays,
             xlab = "Type of spray", ylab = "Insect count",
             main = "InsectSprays data", varwidth = TRUE, col = "lightgray")
     fm1 <- aov(count ~ spray, data = InsectSprays)
     summary(fm1)
     opar <- par(mfrow = c(2,2), oma = c(0, 0, 1.1, 0))
     plot(fm1)
     fm2 <- aov(sqrt(count) ~ spray, data = InsectSprays)
     summary(fm2)
     plot(fm2)
     par(opar)

