Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

3
  • 1
    $\begingroup$ Note that SpatialMedian requires you to load the MultivariateStatistics package in versions of Mathematica before 11.1. Also note that the SpatialMedian does not calculate the "median" as the term is usually used. (I agree it's probably the simplest thing to get at what the OP is asking for, though.) $\endgroup$ Commented May 21, 2018 at 13:41
  • $\begingroup$ Median also work but it takes the median componentwise. This is however not rotationindependent. (But if the different axes have different scaling, this might not be a problem at all...) $\endgroup$ Commented May 21, 2018 at 13:51
  • 1
    $\begingroup$ +1 It should be mentioned that there are many many different types of medians for multivariate data because the univariate median doesn't generalize to higher dimensions. I only see "Median" and "SpatialMedian" implemented in MMA but there are others such as Oja's Simplex Median, Beach and the Halfspace Median, Simplical Depth Median, and Convex Hull Stripping Median. Each one has its own advantages, disadvantages, robustness, computational complexity, etc. $\endgroup$ Commented May 21, 2018 at 16:04