Hello!
For my research, I am trying to find a suitable method for finding collinear columns in a noisy matrix C. I want to try out different algorithms for this task, and one I would like to test is the dendrogramm function. The dendrogramm function is clustering the rows, therefore I am taking the transpose of the matrix C.' to group the columns, and using the following code:
tree = linkage(C.', 'average', 'correlation')
dendrogramm(tree)
My problem is now, that my matrix is containing complex numbers, and I want to cluster the columns by their inner product. However, MATLAB returns the following error:
Error using internal.stats.linkagemex
Function linkagemex only supports real input.
Error in linkage (line 259)
Z = internal.stats.linkagemex(Y,method,pdistArg, memEff);
Error in dendro(line 14)
tree = linkage(C.', 'average', 'correlation');
Apparently, the linkage function that generates the tree for the dendrogramm is only accepting real data. Do I need to rewrite the linkage function for my purposes, or is there a smoother way to work this out?
Thanks in advance for your help.
EDIT: Typo