In the paper, you need to draw pictures for comparison. I feel that it is more convenient to draw matlab. First put the pictures you drew and the matlab code on it.
y=[300 311;390 425; 312 321; 250 185; 550 535; 420 432; 410 520;];
b=bar(y);
grid on;
ch = get(b,'children');
set(gca,'XTickLabel',{'0','1','2','3','4','5','6'})
set(ch,'FaceVertexCData',[1 0 1;0 0 0;])
legend('XXX-based algorithm','YY-based algorithm');
xlabel('x axis ');
ylabel('y axis');
Here are some relevant information about matlab bar charts that you saw online:
Record the matlab drawing bar chart.
Extracted from the algorithm comparison of problem classification tasks.
-------------------------------------------------------------------
data = [1.0, 1.0, 0.565, 0.508, 0.481, 0.745];
b = bar(data);
ch = get(b,'children');
set(ch,'FaceVertexCData',[4;2;3;1;5;6])
%set(gca,'XTickLabel',{'Sina all','Sina travel','S&S','x','mi'})
%set(gca,'XTickLabel',{'Sina all','Sina travel','S&S','STM','CHI','MI'})
set(gca,'XTickLabel',{'SVM(TF)','SVM(TFIDF)','Bayes','Rocchio(TF)','Rocchio(TFIDF)','Class Document Ranking Classification'})
axis([0 7 0.0 1.0])
%%%
ylabel('micro F-measure');
-------------------------------------------------------------------
--------------------------------------------------------------------------------------
data = [20.457, 45.578; 12.016, 22.422];
b = bar(data);
ch = get(b,'children');
set(gca,'XTickLabel',{'Training process','Testing process'})
legend('Classification algorithm based on class document ranking','Classification algorithm combined with bigram');
ylabel('Time taken (unit: seconds)');
--------------------------------------------------------------------------------------
How to set different colors for each bar in Matlab Bar graph?
How to set different colors for each bar in Matlab Bar graph?
Friday, May 15, 2009 15:39
It's easy to create Bar graphs in Matlab:
How to make each Bar color different in Matlab? |
Reprinted from:/