Setting color to text from a colormap
7 次查看(过去 30 天)
显示 更早的评论
I have generated the following figure, the numbers are the correlatios from the scatter plot, i was thinking of changing the colour of the numbers to be representative of the correlation.
I used the following to display the correlations:
subplot_tight(numCols,numCols,N)%,axis square;
A=round(corr(Long_Lat_Data(:,i),Long_Lat_Data(:,j)),3); %rounding the correlation value to 3 decimal places to save space on plot
set(gca,'XTick',[])
set(gca,'YTick',[])
str = {A};
% axis([0 2 0 2])
t = text(0.2,0.5,str);
t(1).FontSize = 8;
0 个评论
采纳的回答
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Orange 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!