Reputation: 641
is there a way to detect an outlier from proc means while calculating min max Q1 and Q3? the box plot procedure is not working on my SAS and I am trying to perform a boxplt in excel with the values from SAS.
Upvotes: 0
Views: 4915
Reputation: 21264
If you want a 'standard boxplot' use the outbox= option in SAS to create the standard data set used for a box plot.
proc boxplot data=sashelp.class;
plot age*sex / outbox = xyz;
run;
Upvotes: 0
Reputation: 63424
Assuming you have a specific definition for what an outlier is, PROC UNIVARIATE can calculate the value that appears at that percentile using the PCTLPTS keyword on the OUTPUT statement. It also will identify extreme observations individually, so you can see the top few observations (if you have few enough observations that the number of extremes is likely to be <= 5).
The paper A SAS Application to Identify and Evaluate Outliers goes over a few of the ways you can look at outliers, including box plots and PROC UNIVARIATE, and includes some regression-based approaches as well.
Upvotes: 2