Reordering the dendrogram according to the class labels