# Isotonic regression

An example of isotonic regression

In numerical analysis, isotonic regression (IR) involves finding a weighted least-squares fit $x\in \Bbb{R}^n$ to a vector $a\in \Bbb{R}^n$ with weights vector $w\in \Bbb{R}^n$ subject to a set of non-contradictory constraints of kind $x_i \ge x_j$.

Such constraints define partial order or total order and can be represented as a directed graph $G=(N,E)$, where N is the set of variables involved, and E is the set of pairs (i, j) for each constraint $x_i \ge x_j$. Thus, the IR problem corresponds to the following quadratic program (QP):

$\min \sum_{i=1}^n w_i (x_i - a_i)^2$ $\text{subject to }x_i\ge x_j~ \text{ for all } (i,j)\in E.$

In the case when $G=(N,E)$ is a total order, a simple iterative algorithm for solving this QP is called the pool adjacent violators algorithm (PAVA). Best and Chakravarti (1990) have studied the problem as an active set identification problem, and have proposed a primal algorithm in O(n), the same complexity as the PAVA, which can be seen as a dual algorithm.[1]

IR has applications in statistical inference, for example, to fit of an isotonic curve to mean experimental results when an order is expected. A benefit of isotonic regression is that it does not assume any form for the target function, such as linearity assumed by linear regression.

Another application is nonmetric multidimensional scaling,[2] where a low-dimensional embedding for data points is sought such that order of distances between points in the embedding matches order of dissimilarity between points. Isotonic regression is used iteratively to fit ideal distances to preserve relative dissimilarity order.

Isotonic regression is also sometimes referred to as monotonic regression. Correctly speaking, isotonic is used when the direction of the trend is strictly increasing, while monotonic could imply a trend that is either strictly increasing or strictly decreasing.

Isotonic Regression under the $L_p$ for $p>0$ is defined as follows:

$\min \sum_{i=1}^n w_i |x_i - a_i|^p$ $\mathrm{subject~to~}x_i\ge x_j~ \text{ for all } (i,j)\in E.$

## Simply ordered case

To illustrate the above, let $x_1 \leq x_2 \leq \ldots \leq x_n$, and $f(x_1) \leq f(x_2) \leq \ldots \leq f(x_n)$, and $w_i \geq 0$.

The isotonic estimator, $g^*$, minimizes the weighted least squares-like condition:

$\min_g \sum_{i=1}^n w_i (g(x_i) - f(x_i))^2$

Where $g$ is the unknown function we are estimating, and $f$ is a known function.

Software has been developed in the R statistical package for computing isotone (monotonic) regression.[3]

## References

1. ^ Best, M.J.; & Chakravarti N. (1990). "Active set algorithms for isotonic regression; a unifying framework". Mathematical Programming 47: 425–439. doi:10.1007/BF01580873.
2. ^ Kruskal, J. B. (1964). "Nonmetric Multidimensional Scaling: A numerical method". Psychometrika 29 (2): 115–129. doi:10.1007/BF02289694.
3. ^ De Leeuw, Jan; K. Hornik; P. Mair (2009). "Isotone Optimization in R: Pool-Adjacent-Violators Algorithm (PAVA) and Active Set Methods". Journal of statistical software 32 (5): 1.