Adjust the height attr in all of the dendrogram nodes so that the tree will have a distance of 1 unit between each parent/child nodes. It can be thought of as ranking the branches between themselves.
This is intended for easier comparison of the topology of two trees.
Notice that this function changes the height of all the leaves into 0, thus erasing the effect of hang.dendrogram (which should be run again, if that is the visualization you are intereted in).
rank_branches(dend, diff_height = 1, ...)
A dendrogram, after adjusting the height attr in all of its branches.