フィルターのクリア

plot curve with error bars

5 ビュー (過去 30 日間)
best16 programmer
best16 programmer 2017 年 6 月 7 日
回答済み: Star Strider 2017 年 6 月 7 日
I have two vectors,how can i calculate the standard deviation for each element so i can plot the error bars in the curve.
thank you

採用された回答

Star Strider
Star Strider 2017 年 6 月 7 日
One approach:
x = 1:10; % Create Data (Independent Variable)
V1 = randn(1, 10); % Create Data (Row Vectors)
V2 = randn(1, 10);
V12_sd = std([V1; V2]); % Standard Deviation
V12_mean = mean([V1; V2]); % Mean
figure(1)
errorbar(x, V12_mean, V12_sd)
grid

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeProgramming についてさらに検索

製品

Community Treasure Hunt

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

Start Hunting!

Translated by