

plot.factor {base}                           R Documentation

_P_l_o_t_t_i_n_g _F_a_c_t_o_r _V_a_r_i_a_b_l_e_s

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

     This functions implements a ``scatterplot'' method for
     `factor' arguments of the generic `plot' function.
     Actually, `boxplot' or `barplot' are used when appro-
     priate.

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

     plot.factor(x, y, legend.text = levels(y), ...)

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

     x,y: numeric or factor.  `y' may be missing.

legend.text: a vector of text used to construct a legend for
          the plot. Only used if `y' is present and a fac-
          tor.

     ...: Further arguments to `plot', see also `par'.

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

     `plot.default', `plot.formula', `barplot', `boxplot'.

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

     data(PlantGrowth)
     plot(PlantGrowth)                                # -> plot.data.frame
     plot(weight ~ group, data = PlantGrowth)         # numeric vector ~ factor
     plot(cut(weight, 2) ~ group, data = PlantGrowth) # factor ~ factor

     plot(PlantGrowth$group, axes=FALSE, main="no axes")# extremly silly

