84 lines
2.2 KiB
Mathematica
84 lines
2.2 KiB
Mathematica
|
|
function createfigure(xvector1, yvector1, xvector2, yvector2, xvector3, yvector3)
|
|||
|
|
%CREATEFIGURE(XVECTOR1,YVECTOR1,XVECTOR2,YVECTOR2,XVECTOR3,YVECTOR3)
|
|||
|
|
% XVECTOR1: bar xvector
|
|||
|
|
% YVECTOR1: bar yvector
|
|||
|
|
% XVECTOR2: bar xvector
|
|||
|
|
% YVECTOR2: bar yvector
|
|||
|
|
% XVECTOR3: bar xvector
|
|||
|
|
% YVECTOR3: bar yvector
|
|||
|
|
|
|||
|
|
% Auto-generated by MATLAB on 11-Feb-2015 17:32:07
|
|||
|
|
|
|||
|
|
% Create figure
|
|||
|
|
figure1 = figure('Name','<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֱ<EFBFBD><EFBFBD>ͼ','Color',[1 1 1]);
|
|||
|
|
|
|||
|
|
% Create axes
|
|||
|
|
axes1 = axes('Parent',figure1,...
|
|||
|
|
'Position',[0.0920853080568723 0.470619469026549 0.20649289099526 0.372300884955752],...
|
|||
|
|
'FontSize',13);
|
|||
|
|
% Uncomment the following line to preserve the X-limits of the axes
|
|||
|
|
% xlim(axes1,[-4 4]);
|
|||
|
|
% Uncomment the following line to preserve the Y-limits of the axes
|
|||
|
|
% ylim(axes1,[0 6]);
|
|||
|
|
box(axes1,'on');
|
|||
|
|
hold(axes1,'all');
|
|||
|
|
|
|||
|
|
% Create bar
|
|||
|
|
bar(xvector1,yvector1,'FaceColor',[0 0 0],'Parent',axes1);
|
|||
|
|
|
|||
|
|
% Create xlabel
|
|||
|
|
xlabel('<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>%','FontSize',13);
|
|||
|
|
|
|||
|
|
% Create ylabel
|
|||
|
|
ylabel('<EFBFBD><EFBFBD><EFBFBD><EFBFBD>','FontSize',13);
|
|||
|
|
|
|||
|
|
% Create title
|
|||
|
|
title('<EFBFBD><EFBFBD><EFBFBD><EFBFBD>A','FontSize',13);
|
|||
|
|
|
|||
|
|
% Create axes
|
|||
|
|
axes2 = axes('Parent',figure1,'XTick',[-12 -6 0 6 12],...
|
|||
|
|
'Position',[0.350370561164917 0.466814159292035 0.20649289099526 0.372300884955752],...
|
|||
|
|
'FontSize',13);
|
|||
|
|
% Uncomment the following line to preserve the X-limits of the axes
|
|||
|
|
% xlim(axes2,[-12 12]);
|
|||
|
|
% Uncomment the following line to preserve the Y-limits of the axes
|
|||
|
|
% ylim(axes2,[0 8]);
|
|||
|
|
box(axes2,'on');
|
|||
|
|
hold(axes2,'all');
|
|||
|
|
|
|||
|
|
% Create bar
|
|||
|
|
bar(xvector2,yvector2,'FaceColor',[0 0 0],'Parent',axes2);
|
|||
|
|
|
|||
|
|
% Create xlabel
|
|||
|
|
xlabel('<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>%','FontSize',13);
|
|||
|
|
|
|||
|
|
% Create title
|
|||
|
|
title('<EFBFBD><EFBFBD><EFBFBD><EFBFBD>B','FontSize',13);
|
|||
|
|
|
|||
|
|
% Create ylabel
|
|||
|
|
ylabel('<EFBFBD><EFBFBD><EFBFBD><EFBFBD>','FontSize',13);
|
|||
|
|
|
|||
|
|
% Create axes
|
|||
|
|
axes3 = axes('Parent',figure1,'XTick',[-12 -6 0 6 12],...
|
|||
|
|
'Position',[0.606286146026517 0.463982300884956 0.20649289099526 0.372300884955752],...
|
|||
|
|
'FontSize',13);
|
|||
|
|
% Uncomment the following line to preserve the X-limits of the axes
|
|||
|
|
% xlim(axes3,[-12 12]);
|
|||
|
|
% Uncomment the following line to preserve the Y-limits of the axes
|
|||
|
|
% ylim(axes3,[0 5]);
|
|||
|
|
box(axes3,'on');
|
|||
|
|
hold(axes3,'all');
|
|||
|
|
|
|||
|
|
% Create bar
|
|||
|
|
bar(xvector3,yvector3,'FaceColor',[0 0 0],'Parent',axes3);
|
|||
|
|
|
|||
|
|
% Create xlabel
|
|||
|
|
xlabel('<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>%','FontSize',13);
|
|||
|
|
|
|||
|
|
% Create ylabel
|
|||
|
|
ylabel('<EFBFBD><EFBFBD><EFBFBD><EFBFBD>','FontSize',13);
|
|||
|
|
|
|||
|
|
% Create title
|
|||
|
|
title('<EFBFBD><EFBFBD><EFBFBD><EFBFBD>C','FontSize',13);
|
|||
|
|
|