How can I change color and font size in plotconfusion figures?
古いコメントを表示
Hi!
I want to change the color of the fields of the confusion matrix and also to change the font size of the entries in the fields. I know I can do it in the plot editor, but I prefer to do it automatically perhaps with set and get? I couldn't find anything in google on that topic.
Thanks for your help!
Just a little example:
a=[1 1 0 1 0 0 1 0 1 0 1 1 0 0 1 0 0 0 1 0];
b=[1 0 1 1 0 1 1 0 1 0 1 0 0 0 1 1 0 0 1 0];
figure(1)
plotconfusion(a,b)
採用された回答
その他の回答 (1 件)
Shivang Patel
2015 年 5 月 4 日
0 投票
My confusion matrix size is 19x19.. so, Is there any convenient way to display clearly...because u know when 19x19's confusionMatrix plot it's a overlap some value...n everything hochpoch !!!
Thanks for Advance...
4 件のコメント
sherok mohamed
2017 年 7 月 22 日
Did you find a solution? .... I have the same problem
Baptiste Ottino
2017 年 8 月 8 日
Maybe with this number of classes you should consider another way of displaying the results, like a bar plot for example.
Walter Roberson
2017 年 8 月 8 日
No, there is no convenient way. You would have to do the plotconfusion() and then find the created objects and move them into a large container that you had created scrollbars for.
Abdullah Al-Maliki
2020 年 11 月 27 日
Use the command from the accepted answer above just change the font size from 20 to 5, Iused it and it helped to better show a 26 class confusion matrix.
set(findobj(gca,'type','text'),'fontsize',5)
PS I know this is an old thread but I'm posting this reply to help whoever might needed!
カテゴリ
ヘルプ センター および File Exchange で Matrix Indexing についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!