dend <- as.dendrogram(hclust(dist(USArrests)))
labels(dend)
## Not run:
# # require(microbenchmark)
# microbenchmark::microbenchmark(dendextendRcpp::stats_labels.dendrogram(dend),
# dendextendRcpp::dendextendRcpp_labels.dendrogram(dend),
# times = 100)
# # about 30 times faster. It is faster the larger the tree is.
# ## End(Not run)
Run the code above in your browser using DataLab