Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

To resolve issues starting MATLAB on Mac OS X 10.10 (Yosemite) visit: http://www.mathworks.com/matlabcentral/answers/159016

boxplot insists on removing outliers, is there an option to disable outlier removal?

Asked by John Soong on 30 Nov 2012

I want to completely disable outlier removal. My data is not normally distributed, so I need all the points to affect the mean.

0 Comments

John Soong

Tags

Products

No products are associated with this question.

1 Answer

Answer by Tom Lane on 30 Nov 2012

Can you explain more about what you want? Ordinarily the boxplot doesn't remove outliers, but instead shows them as separate markers on the plot. Is that what you want to prevent? Here are two invocations of boxplot, one of which includes the outlier in the box-like part rather than as a separate marker:

boxplot([1:10,100]')
boxplot([1:10,100]','whisker',1000)

The line across the center of the box is at the median, not the mean, so the outlier doesn't really affect its value directly.

0 Comments

Tom Lane

Contact us