p1=[1,1,1];
p2=[2,2,2];
p3=[3,3,3];
y=[p1',p2',p3'];
c=bar(y);
color=[1,0,0;0,1,0;0.9,0.9,0.2];
for i=1:3
set(c(i),'FaceColor',color(i,:));
end
pos=get(gcf,'Position');
scale=1.2;
set(gcf,'Position',[pos(1),pos(2),pos(3)/scale,pos(4)/scale]);
set(gca,'XLim',[0.5,3.5]);
legend('PCA','PCA-L1 greedy','PCA-L1 nongreedy','location','Southeast');
xlabel('Feature Number');
ylabel('Recognition Accuracy');
示例
网友评论