By comparing the dendrograms produced by the clustergram object and the "manual" approach i.e. pdist -> linkage -> dendrogram I found they are different, but cannot find an explanation for that difference.
Clustergram documentation says that the default distance used is 'Euclidean' and the default linkage method is 'Average', same parameters I used for pdist and linkage functions.
I thought it might be related with the standardization performed by clustergram, so I used zscore for standardizing first my matrix and then each column separately, but the dendrograms are still different as compared with the one produced by clustergram.
Can somebody explain the reason behind that difference, and how can I use the "manual" approach for getting the same dendrogram?
Many thanks in advance.
Edit: I compared the results obtained by the "manual" approach with the SPSS results and they are the same.
Also I tested all different 'data processing' options with clustergram but the dendrogram keeps being different.