Python implementation of Isotonic Estimator in Wicksell Problem

The implementation of the library

isotonic_estimator_lib 

is essentially based on the PAVA algorithm. Before the publication of this Python Package there was no library in Python that contained the PAVA algorithm (it was available only in R-Studio). See here for the official Python Library.

This package implements the isotonic estimator for Wicksell’s problem given in the paper Adaptive and Efficient Isotonic Estimation in Wicksell’s Problem.

How to use the package? After installing the package via the usual command line pip install, the user user can import the package using the lines of code:

from isotonic_estimator_lib import isotonic_estimator

then, having a vector of observed samples Z, the user can obtain the isotonic estimator together with its plot by running:

max_xs = max(Z)
res = isotonic_estimator.estimator(max_xs,Z)

where max_xs is needed for plotting purposes only. The resulting estimated cdf F of the hidden radii distribution is now stored into res. The resulting plot should look as follows:

We have also designed a test application in tkinter which is included in the package and where the user can visualize the performance of the isotonic estimator. After running the following code:

from isotonic_estimator_lib import tester_quality
tester_quality.tester()

a pop-up window will open asking to input a test hidden cdf F which can be chosen between the following set of distributions: “gamma, chi, betaprime, pareto, lognormal, truncnorm, arcsine, fatiguelife, weibull”. The input is case sensitive. If the user gives non acceptable inputs, the tester will automatically produce an error. The suggested number of samples is 200, and it is not recommended to choose a value higher than 1000. The tester will produce some plots that illustrate the performance of the isotonic estimator. The resulting plot should look like this:

Francesco Gili
Francesco Gili

I am a PhD candidate in Mathematical Statistics at TU Delft under the supervision of Aad van der Vaart and Geurt Jongbloed.