In this repository you can find the code used in the article Finite Sample Guarantees For Quantile Estimation - An Application to Detector Threshold Tuning. You can find the arXiv version of the article here.
In this article, we determine how many independent and identically distributed samples of a certain distribution are needed to estimate the distribution's quantile such that the estimate is close to the true quantile with a high probability. We apply these sample guarantees in the tuning of a detector threshold.
This repository provides the code to reproduce the result presented in the paper. The code was originally coded in MATLAB, but we also provide two Julia scripts to reproduce the simulated results.
The code can be divided into the following three separate parts:
-
Comparing the finite guarantees
To reproduce Fig. 2 that compares the three finite guarantees we propose in our article one can...
-
USING MATLAB
...run the file
ComparisonOfSampleGuarantees.m
, which usesFiniteSampleBoundBetaConfInt.m
. -
USING JULIA
...run the file
ComparisonOfSampleGuarantees.jl
.
-
-
Creating histograms for different distributions
To reproduce Fig. 3 that compares the performance of two guarantees for three different distributions one can...
-
USING MATLAB
...run the file
HistogramOfEmpiricalFarForFiniteGuarantees.m
, which uses the fileFiniteSampleBoundBetaConfInt.m
. -
USING JULIA
...run the file
HistogramOfEmpiricalFarForFiniteGuarantees.jl
.
-
-
Applying the results to real data
To reproduce Fig. 4 and Fig. 5 one can run the file
HistogramOfEmpiricalFarForFiniteGuarantees.m
, which uses the real data saved inDataOfTCLabForDetectorTuning.mat
and the fileFiniteSampleBoundBetaConfInt.m
. Note for reproducing these result only MATLAB code is available!