KMeans                 package:Rcmdr                 R Documentation

_K-_M_e_a_n_s _C_l_u_s_t_e_r_i_n_g _U_s_i_n_g _M_u_l_t_i_p_l_e _R_a_n_d_o_m _S_e_e_d_s

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

     Finds a number of k-means clusting solutions using R's 'kmeans'
     function, and selects as the final solution the one that has the
     minimum total within-cluster sum of squared distances.

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

     KMeans(x, centers, iter.max=10, num.seeds=10)

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

       x: A numeric matrix of data, or an object that can be coerced to
          such a matrix (such as a numeric vector or a dataframe with
          all numeric columns).

 centers: The number of clusters in the solution.

iter.max: The maximum number of iterations allowed.

num.seeds: The number of different starting random seeds to use. Each
          random seed results in a different k-means solution.

_V_a_l_u_e:

     A list with components: 

 cluster: A vector of integers indicating the cluster to which each 
          point is allocated.

 centers: A matrix of cluster centres (centroids).

withinss: The within-cluster sum of squares for each cluster.

tot.withinss: The within-cluster sum of squares summed across clusters.

betweenss: The between-cluster sum of squared distances.

    size: The number of points in each cluster.

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

     Dan Putler

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

     'kmeans'

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

       data(USArrests)
       KMeans(USArrests, centers=3, iter.max=5, num.seeds=5)

