problem with error bar

조회 수: 4 (최근 30일)
Villanova
Villanova 2011년 10월 1일
Hi. I want to use errorbar(x,y,std) to get the error bar. I was wondering if x and y are vectors with 10 data point each. how do I write the code for std to have the same matching (10X1) dimension. Thanks

채택된 답변

Wayne King
Wayne King 2011년 10월 1일
e = std(y)*ones(size(y));
  댓글 수: 1
Wayne King
Wayne King 2011년 10월 1일
As in:
x = 1:10;
y = randn(10,1);
e = std(y)*ones(10,1);
errorbar(x,y,e)

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by