Computing the Oja Median in R: The Package OjaNP

Daniel Fischer, Karl Mosler, Jyrki Möttönen, Klaus Nordhausen, Oleksii Pokotylo, Daniel Vogel

Research output: Contribution to journalArticle


The Oja median is one of several extensions of the univariate median to the multivariate case. It has many desirable properties, but is computationally demanding. In this paper, we first review the properties of the Oja median and compare it to other multivariate medians. Then, we discuss four algorithms to compute the Oja median, which are implemented in our R package OjaNP. Besides these algorithms, the package contains also functions to compute Oja signs, Oja signed ranks, Oja ranks, and the related scatter concepts. To illustrate their use, the corresponding multivariate one-and C-sample location tests are implemented.

Original languageEnglish
Article number8
Pages (from-to)1-36
Number of pages36
JournalJournal of Statistical Software
Issue number8
Publication statusPublished - 23 Feb 2020


  • Oja median
  • Oja signs
  • Oja signed ranks
  • Oja ranks
  • R,C,C++
  • R, C++
  • R
  • C plus

ASJC Scopus subject areas

  • Software
  • Statistics and Probability
  • Statistics, Probability and Uncertainty

Fingerprint Dive into the research topics of 'Computing the Oja Median in R: The Package OjaNP'. Together they form a unique fingerprint.

  • Cite this

    Fischer, D., Mosler, K., Möttönen, J., Nordhausen, K., Pokotylo, O., & Vogel, D. (2020). Computing the Oja Median in R: The Package OjaNP. Journal of Statistical Software, 92(8), 1-36. [8].