If outliers are not considered, how to include outliers inside whiskers so that they are involved in the calculation of the median?
Is the calculation of the median including outliers?
19 ビュー (過去 30 日間)
古いコメントを表示
採用された回答
Voss
2022 年 2 月 13 日
Let's do a test to try to figure it out:
rng(2);
data = randn(1,10);
figure();
plot(data)
med = median(data);
med_no_outlier = median(data(data > min(data)));
figure();
yline(med,'--g');
hold on
yline(med_no_outlier,'--m');
boxplot(data);
The median line from boxplot() matches the median calculated using all the data, so it looks like boxplot() uses all the data to compute the median.
0 件のコメント
その他の回答 (0 件)
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!