Mark smallest bar in 3-D bar plot
조회 수: 3 (최근 30일)
이전 댓글 표시
I have a 3d bar plot where the height of a bar resembles the mean squared error of a function estimator. Wit my code I find the combination of simplex and order which results in the lowest mean squared error which is 6 and 5 respectively. The color of the bars is already in corresponding to its height, however due to the small varaition it is not visible which is actually the smallest. Therefore, I would like to put a marker (arrow, diamond, etc) on the smallest bar.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/354533/image.jpeg)
figure(2)
bar = bar3(mse_mat);
for i = 1:size(mse_mat,2)
zdata = ones(6*size(mse_mat,1),4);
k = 1;
for j = 0:6:(6*size(mse_mat,1)-6)
zdata(j+1:j+6,:) = mse_mat(k,i);
k = k+1;
end
set(bar(i),'Cdata',zdata)
end
xlabel('Simplex order')
ylabel('Number of simplices')
yticks((2:2:max_simplices)/2)
yticklabels(split(num2str(2:2:max_simplices)))
댓글 수: 0
답변 (1개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Annotations에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!