Maybe you can adjust your original data before you using clustergram. That is mean you can do data translation. You can get the middle value of your data, then let original data to minus this value. At last, you can use this new data to clustergram and you will get what you wanted.
Question about Clustergram colors
2 次查看(过去 30 天)
显示 更早的评论
Dear Matlab Users,
I have a problem understanding which part of clustergram function I need to modify to adapt it to my input data. I have two columns of data ranging from 0-100 (percentage values) in two conditions, and I would like to apply clustergram to visualize how the variables correlate in these two conditions. So some variables (rows) will have low percentage in both conditions, some high in one condition and low in the other one and so on. When I apply basic clustergram function, I receive the following graph.
s= clustergram(vars(:,1:2),'ColumnPdist', 'correlation');
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/165682/image.jpeg)
Based on the nature of my data I don't have any negative values (no green), and many values more than the default 'DisplayRange' of 3. Therefore I am limited to what appears to be solid red and black.
Could you please help me understand which parameters of the clustergram function I need to change in order to get instead of this a gradient of green and red colors for my data?
Thank You in advance,
Noushin
0 个评论
回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Expression Analysis 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!