title: What is the clustering algorithm used by hclust in R?
body: <p>I've been using the hclust algorithm, here is the code : </p>
  
  <pre><code>hc = hclust(dist(mydata))
  ## tweeking some parameters for plotting a dendrogram
  # set background color
  op = par(bg="#DDE3CA")
  # plot dendrogram
  plot(hc, col="#487AA1", col.main="#45ADA8", col.lab="#7C8071",
       col.axis="#F38630", lwd=3, lty=3, sub='', hang=-1, axes=FALSE)
  # add axis
  axis(side=2, at=seq(0, 400, 100), col="#F38630",
       labels=FALSE, lwd=2)
  # add text in margin
  mtext(seq(0, 400, 100), side=2, at=seq(0, 400, 100),
        line=1, col="#A38630", las=2)
  par(op)
  </code></pre>
  
  <p>What variation of clustering is hclust using as I want to implement it programmatically ? Is it same as implementation on wikipedia : <a href="http://en.wikipedia.org/wiki/Hierarchical_clustering" rel="nofollow">http://en.wikipedia.org/wiki/Hierarchical_clustering</a> ?</p>