plot.diana              package:cluster              R Documentation

_P_l_o_t_s _o_f _a _D_i_v_i_s_i_v_e _H_i_e_r_a_r_c_h_i_c_a_l _C_l_u_s_t_e_r_i_n_g

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

     Creates plots for visualizing a 'diana' object.

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

     ## S3 method for class 'diana':
     plot(x, ask = FALSE, which.plots = NULL, main = NULL,
                sub = paste("Divisive Coefficient = ", round(x$dc, digits = 2)),
                adj = 0, nmax.lab = 35, max.strlen = 5, xax.pretty = TRUE, ...)

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

       x: an object of class '"diana"', typically created by
          'diana(.)'.

     ask: logical; if true and 'which.plots' is 'NULL', 'plot.diana'
          operates in interactive mode, via 'menu'.

which.plots: integer vector or NULL (default), the latter producing
          both plots.  Otherwise, 'which.plots' must contain integers
          of '1' for a _banner_ plot or '2' for a dendrogramm or
          ``clustering tree''.

main, sub: main and sub title for the plot, each with a convenient
          default.  See documentation for these arguments in
          'plot.default'.

     adj: for label adjustment in 'bannerplot()'.

nmax.lab: integer indicating the number of labels which is considered
          too large for single-name labelling the banner plot.

max.strlen: positive integer giving the length to which strings are
          truncated in banner plot labeling.

xax.pretty: logical or integer indicating if 'pretty(*, n =
          xax.pretty)' should be used for the x axis. 'xax.pretty =
          FALSE' is for back compatibility.

     ...: graphical parameters (see 'par') may also be supplied and are
          passed to 'bannerplot()' or 'pltree()', respectively.

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

     When 'ask = TRUE', rather than producing each plot sequentially,
     'plot.diana' displays a menu listing all the plots that can be
     produced. If the menu is not desired but a pause between plots is
     still wanted one must set 'par(ask= TRUE)' before invoking the
     plot command.

     The banner displays the hierarchy of clusters, and is equivalent
     to a tree. See Rousseeuw (1986) or chapter 6 of Kaufman and
     Rousseeuw (1990). The banner plots the diameter of each cluster
     being splitted. The observations are listed in the order found by
     the 'diana' algorithm, and the numbers in the 'height' vector are
     represented as bars between the observations.

     The leaves of the clustering tree are the original observations. A
     branch splits up at the diameter of the cluster being splitted.

_S_i_d_e _E_f_f_e_c_t_s:

     An appropriate plot is produced on the current graphics device.
     This can be one or both of the following choices: 
      Banner 
      Clustering tree

_N_o_t_e:

     In the banner plot, observation labels are only printed when the
     number of observations is limited less than 'nmax.lab' (35, by
     default), for readability. Moreover, observation labels are
     truncated to maximally 'max.strlen' (5) characters.

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

     see those in 'plot.agnes'.

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

     'diana', 'diana.object', 'twins.object', 'par'.

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

     example(diana)# -> dv <- diana(....)

     plot(dv, which = 1, nmax.lab = 100)

     ## wider labels :
     op <- par(mar = par("mar") + c(0, 2, 0,0))
     plot(dv, which = 1, nmax.lab = 100, max.strlen = 12)
     par(op)

