Unwanted marker in logarithmic boxchart
2 ビュー (過去 30 日間)
古いコメントを表示
Hello
When I use logarithmic scale for the y-axis of my box plot, a marker appears at the right-bottom corner of the axes. Here's a mininmal code to reproduce the behavior:
x = categorical(1:5);
y = rand(1, 5);
figure;
boxchart(x, y)
set(gca, 'YScale', 'log')
The result is the following:
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/745519/image.png)
My question is how to get rid of the unwanted marker.
0 件のコメント
回答 (1 件)
Kevin Holly
2021 年 9 月 21 日
Behnam,
The Dev team is currently working on this issue. A workaround for now is to use boxplot instead.
x = 1:5;
y = rand(1, 5);
figure;
boxplot(x, y)
xticklabels({'1','2','3','4','5'})
set(gca, 'YScale', 'log')
2 件のコメント
Kevin Holly
2021 年 9 月 23 日
編集済み: Kevin Holly
2021 年 9 月 23 日
Behnam,
Here is a workaround:
x = categorical(1:5);
y = rand(1, 5);
figure;
boxchart(x, y)
set(gca, 'YScale', 'log')
handle = gca;
handle.Children.MarkerStyle = 'none';
Or Alternatively,
boxchart(x, y,'MarkerStyle','none')
set(gca, 'YScale', 'log')
参考
カテゴリ
Help Center および File Exchange で Log Plots についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!