Dashed confidence intervals and xlabel
이전 댓글 표시
Today is my "plot day". I am trying to fit subplot with shaded confidence intervals (find the dataset attached). Besides, I have also a problem with xlabel. Let me write the code that is easier:
% data
data = xlsread('Q.xls')
lines = data(:,1:5)
lower_bound = data(:,6:10)
upper_bound = data(:,11:15)
k = 5
for j = 1:k
subplot(3, 2, j);
plot(lines(:,j), 'LineWidth',1,'Color', [0 0 0.5]);
hold on
fill(lower_bound(:,j), upper_bound(:,j), 'r', 'FaceAlpha', .1, 'EdgeColor', 'none');
xlabel('months');
yline(0, '-')
end
I also tried to use 'patch' but it didn't work either. What am I doing wrong? Besides, I would like 'xlabel' to be displayed only at the end of the first and second column; now, instead, it appears belowe every graph.
Can anyone help me fix this?
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Surface and Mesh Plots에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
