how to eliminate outlier in spotfire box plots

旧巷老猫 提交于 2019-12-30 11:15:11

问题


Thanks for your help in advance.

Regards, Raj


回答1:


Adding the values to MAX() values would skew the data even if it were possible. There are two hacks to do this though.

  1. Right Click > Properties > Y-Axis > set the MIN range value and MAX range values to something that would eliminate all outliers. This is really only suitable for box plots that are close in all values to each other (all percentiles)
  2. On your toolbar click Insert > Calculated Column > choose the correct data table and paste in the expression below. You will need to replace the [x-axisColumn] and the [y-axisColumn] with what ever is on the X and Y axis of your box plot. To find out what this is, right click on your box plot > properties > X-Axis and there it will tell you what your X-Axis column is. Do this for the Y-Axis as well. This will create a column called "Outlier" in your data table with three options: NotOutlier, UpperOutlier, LowerOutlier. You just need to uncheck "UpperOutlier" and "LowerOutlier" to remove your outliers.

`

case
when [y-axisColumn]<(Q1([y-axisColumn]) - (1.5 * IQR([y-axisColumn]) OVER ([x-axisColumn]))) then "LowerOutlier"
when [y-axisColumn]>(Q3([y-axisColumn]) + (1.5 * IQR([y-axisColumn]) OVER ([x-axisColumn]))) then "UpperOutlier"
else "NotOutlier"
end as [Outlier]

`



来源:https://stackoverflow.com/questions/38397514/how-to-eliminate-outlier-in-spotfire-box-plots

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!