## 5 Application to Indirect Reference Interval Estimation in Laboratory Medicine
Therefore, we take the medians of the weighted means and standard deviations to estimate the mean and standard deviation of the normal distribution representing the healthy sub-collective. Finally, the reference interval is estimated from the theoretical 2.5%- and 97.5%-quantiles of this normal distribution. Algorithm 3 describes this procedure in more detail. As a range for the \(\delta\)-values, we choose as the largest distance the maximum of the (squared) distances between the median and the 10%- and the 90%-quantiles, respectively. In Algorithm 3, \(x_{\beta}\) denotes the \(\beta\)-quantile of the sample, \(x\). The smallest distance is chosen as the difference between the 60%- and 40%-quantiles of the values. \(\alpha\) is set to a quarter of the maximum value for \(\delta\). In case \(\alpha\) is too small, \(\alpha\) will be automatically adapted in the call of Algorithm 2. We decrease the noise distance in 100 steps of equal length. Of course, one could also use more or fewer steps, but our experiments indicated that an increase in the number of steps would not change the results significantly. The last lines of the code compute the 2.5%- and 97.5%-quantiles of the corresponding normal distribution whose parameters were estimated by the median of the means and the median of the standard deviations computed in the for-loop. \(\Phi\) denotes the cumulative distribution function of the standard normal distribution. It should be noted that the call of the function oneClusterMod in Algorithm 3 is modified in the actual implementation in order to avoid repeated computations of sums of powers of the data for the coefficients of the cubic polynomial in Equation (15). Because only the values \(\delta\) and \(\alpha\) are subject to changes in Algorithms 2 and 3, the sums of powers of the data need to be computed only once initially. As a first example, we consider a synthetic dataset that simulates haemoglobin (HGB) in women with a reference interval from 12-16 [g/dL]. We simulated 500 values from a normal distribution with a mean of 14 and a standard deviation of 1 and added another 50 pathological values from a normal distribution with a mean of 11 and a standard deviation of 1. The last row in Table 1 shows the results for the methods reflimR and refineR [31], available as R packages and our above-described approach oneClusterRI detailed in Algorithm 3. The other rows in Table 1 are the corresponding estimates for the reference intervals for men for the analytes albumin (ALB), alkaline phosphatase (ALP), alanine aminotransferase (ALT), aspartate transferase (AST), bilirubin (BIL), cholinesterase (CHE), cholesterol (CHOL), creatinine (CREA), gamma-glutamyl transferase (GGT), and total protein (PROT) \begin{table}
\begin{tabular}{l c c c c c c} \hline \hline  & \multicolumn{2}{c}{**reflimR**} & \multicolumn{2}{c}{**refineR**} & \multicolumn{2}{c}{**oneClusterRI**} \\ \hline  & **Lower** & **Upper** & **Lower** & **Upper** & **Lower** & **Upper** \\ \hline ALB & 35.01 & 51.13 & 37.26 & 50.20 & 36.61 & 50.21 \\ ALP & 29.99 & 101.18 & 36.44 & 98.67 & 34.67 & 91.20 \\ ALT & 10.69 & 65.99 & 10.20 & 65.11 & 12.78 & 64.82 \\ AST & 17.07 & 42.04 & 14.68 & 41.56 & 16.24 & 45.07 \\ BIL & 3.25 & 19.71 & 3.46 & 14.54 & 3.03 & 19.00 \\ CHE & 4.91 & 12.38 & 4.38 & 12.03 & 5.92 & 11.75 \\ CHOL & 3.55 & 7.87 & 3.32 & 7.75 & 4.00 & 7.49 \\ CREA & 60.71 & 115.87 & 59.33 & 113.04 & 63.47 & 112.34 \\ GGT & 9.39 & 61.23 & 9.52 & 55.23 & 9.59 & 64.95 \\ PROT & 64.04 & 81.58 & 64.06 & 81.54 & 66.16 & 80.99 \\ HGB & 11.85 & 15.95 & 11.90 & 15.99 & 12.27 & 15.88 \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Estimated reference intervals for the HCV dataset—a publicly available laboratory dataset—and synthetic data (last row) based on the available R packages reflimR and refineR and our method (oneClusterRI).