필터 지우기
필터 지우기

How can i put error bars in grouped bar plot?

조회 수: 1 (최근 30일)
Arshad
Arshad 2016년 10월 6일
댓글: Arshad 2016년 10월 7일
Hi All, My data are as follow: pw=[900 1200 1500]; % x-axis data
bc=[13.40 38.07 48.53; 14.47 31.53 54.00; 16.37 31.17 52.47]; %Y-axis data
err = [1.222 2.557 3.735 0.933 3.526 2.615 1.994 3.675 1.833]; % errors for y data
I am trying to plot the grouped bar graph with error bars in Matlab 2014b, but I was not successful. I would appreciate if any one can help me in solving this problem.

답변 (1개)

dbmn
dbmn 2016년 10월 7일
In the File-Exchange there is a function that does exactly what you want.
  댓글 수: 1
Arshad
Arshad 2016년 10월 7일
Hi, I tried to use barwith err function and the following code. But it is giving me this message "Undefined function 'barwitherr' for input arguments of type 'double'."
y=[0.33,0.362]; errY=[0.017,0.054]; h=barwitherr(errY,y); set(h(1),'FaceColor','g')

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Bar Plots에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by