title: Clustering with R
body: <p>I have a data.frame, for example:</p>
  
  <pre><code>test&lt;-data.frame(matrix(c(1:5,2:6,3:7),nrow=3))
  
  test&lt;-cbind(rbind(exp(test),test),rbind(test,2*test))
  test
  #          X1         X2        X3        X4        X5 X1 X2 X3 X4 X5
  # 1  2.718282  54.598150  20.08554 403.42879  148.4132  1  4  3  6  5
  # 2  7.389056 148.413159  54.59815  20.08554  403.4288  2  5  4  3  6
  # 3 20.085537   7.389056 148.41316  54.59815 1096.6332  3  2  5  4  7
  # 4  1.000000   4.000000   3.00000   6.00000    5.0000  2  8  6 12 10
  # 5  2.000000   5.000000   4.00000   3.00000    6.0000  4 10  8  6 12
  # 6  3.000000   2.000000   5.00000   4.00000    7.0000  6  4 10  8 14
  </code></pre>
  
  <p>and my distance matrix</p>
  
  <pre><code>dist(test)
  #             1           2           3           4           5
  # 2  471.181726                                                
  # 3 1019.716766  714.553473                                    
  # 4  425.980071  427.331552 1102.568122                        
  # 5  428.325768  426.014214 1101.559808    8.062258            
  # 6  427.427492  425.995993 1100.387152   10.000000    8.062258
  </code></pre>
  
  <p>I have my Hierarchical Clustering (<code>hclust(dist(test))</code>) and I want to put in a group, for example all the lines which the distance is lower than 10 (here for example it would be 4 and 5 and 6) </p>
  
  <p>But in reality, my data.frame is much bigger than that, and I want to do it automatically.</p>