Development of New Robust Optimal Score Function for the Weibull Distributed Error Term in Multilevel Models

A popular robust estimation technique for linear models is the rank-based method as an alternative to the ordinary least square (OLS) and restricted maximum likelihood (REML) in the presence of extreme observations. (is method is applied in machine reliability analysis and quantum engineering, especially in artificial intelligence and optimization problems where outliers are commonly observed. (is technique is also extended for the multilevel model, where the shape of error distribution contributes a significant role in more efficient estimation. In this study, we proposed the Weibull score function for the Weibull distributed error terms in the multilevel model. (e efficiency of the proposed score function is compared with the existing Wilcoxon score function and the traditional method REML via Monte Carlo simulations after adding simulated extreme observations. For small values of shape parameter in Weibull distribution of error term showing the presence of outliers, the Weibull score function was found to be efficient as compared to the Wilcoxon and REML methods. However, for a large value of shape parameter, Wilcoxon score appeared either equally efficient than the Weibull score function. REML is observed least precise in all situations. (ese findings are verified through a real application on test scores data, with a small value of shape parameter, and the Weibull score function turned out the most efficient.


Introduction
e rank-based method is an alternative robust estimation method over conventional estimation techniques of the linear models such as restricted maximum likelihood (REML) and ordinary least square (OLS) when errors are asymmetric due to the presence of outliers. Rank-based fitting works by assigning ranks to the residuals based on a pseudonorm similar to the Euclidean squared norm used in the OLS providing for a robust fit [1]. e rank estimation method is also a popular parameter estimation method in reliability analysis, machine learning, and artificial intelligence, where the structure of error term is positively skewed. e reason for skewness may be due to the presence of one or more extreme observations. For example, if one wants to study the life (reliability) batteries, then some batteries maybe failed at an initial time and some are failed after a long time. Both these times are extreme observations. ese observations are sometimes also called outliers. So, in this situation, we need a ranked estimation method as a robust estimation method alternative to REML and OLS.
Garcia et al. [2] developed a new rank-based constraint handling technique for the solution of engineering optimization problems. e comparison with other techniques revealed the accuracy and robustness of the rank-based technique. Neelima et al. [3] presented a rank-based skeleton extraction algorithm that shows improved performance based on speed, time, rate, and connectivity than various methods in the literature. Li et al. [4] presented a new powerful rank-based procedure for the EWMA control scheme for online sequential monitoring.
is procedure can be used to monitor the location and scale parameters of a continuous distribution. From the simulation study, the rank-based method appeared quite robust to nonnormally distributed data and efficient in detecting various process shifts. Chen et al. [5] advocated that rank regression is a more objective approach for dealing with nonnormal data due to the presence of outliers. is finding is evidenced by comparing the rank-based method with traditional parametric and semiparametric regression models through Monte Carlo simulation and real data examples. Liu et al. [6] proposed estimators of nonparametric coefficients in robust estimation for the varying coefficient partially functional linear regression model (VCPFLM) based on B-spline approximation and rank regression. e proposed estimators are found robust for nonnormal error distribution compared with OLS through a simulation study and real-life dataset. Henry et al. [7] compared rank-based estimation and OLS for the Granger and Lee asymmetric price transmission model. Both estimation methods appeared equivalent for normal data irrespective of the sample size. On the other side, for the data affected by outliers, OLS estimates turned inaccurate. However, the rank-based estimation is robust to outliers in large sample size and produced unbiased estimates. e results of the simulation study confirmed the outperformance of rank-based estimation for asymmetric data with outliers and almost equivalent performance for normal datasets in the context of asymmetric price transmission modeling. e proper choice of a score function leads to asymptotically efficient estimators. e efficiency of robust rank-based analyses is compared with the traditional REML method for normal and nonnormal error distributions. For nonnormal error term in linear models, rank-based estimators attain more efficiency than REML but produce quite a similar efficiency for normal error term [1]. Fixed effect estimates, standard errors, and estimates of variance components are compared through a large simulation study. Rank-based analyses appeared much more powerful and efficient than REML. McKean and Hettmansperger presented a review of the development of rank-based theory for linear models and various extensions [8]. Kloke et al. [9] extended this rank theory for the linear models with cluster-correlated errors for example mixed models and nonlinear models. A complete unified methodology of rank-based analyses is presented in [10]. Usually, rank-based analyses are a robust and efficient estimation method. Nevertheless, this efficiency can be optimized based on the information available regarding the distribution of the error term. e rank-based analysis turns out to be more accurate and efficient when the selected score function is close to the form of 'f'. If the probability density function (pdf ) of u is f (u), then the expression for optimal score function φ f (u) can be obtained through some mathematical derivation [8]. us, the prior knowledge of the distribution of error term would assist in proper choice of score function leading towards efficient regression estimators. e underlying shapes of error distributions can be symmetric, right-tailed, left-tailed, light-, moderate-, and heavy-tailed. One common probability distribution for right-skewed data is the Weibull distribution, considered the case of the righttailed error distribution. e shape of the distribution is right-skewed and controlled by two parameters such as scale (λ > 0) and shape (k > 0). e level of skewness of the Weibull distribution decreases as the value of the shape parameter increases. Weibull distribution mostly occurs in the reliability of products based on design, manufacturing, and development in prelaunch and postlaunch stages [11]. e rank-based estimation method is highly efficient than OLS and REML in the case of the nonnormal error term. e dependent error structure in the error term spoils the normality. e efficiency of the rank-based method can be optimized by selecting the appropriate score function for Weibull distributed error term. In peridynamics, the variability in the brittle fracture can be modeled well by Weibull distribution [12]. Weibull score function would provide the most efficient estimates of standard error. Some research work related to the rank-based estimation method is available in the literature. Mckean and Kloke [13] developed a family of optimal score functions for a skew-normal family of distributions. Additionally, the validity and efficiency of rank-based estimators are compared with MLE and Wilcoxon score through simulation study for skew-normal and contaminated normal distribution. Mckean and Sievers [14] proposed rank score functions suitable for skewed error distributions, specifically for generalized F family of error distributions. ese score functions are bounded and provide a robust and powerful rank analysis for a linear model with application to model the lifetime data. Zhen et al. [15] proposed a new score function of intuitionistic fuzzy values (IFVs). e new score function is capable to overcome the problems of other score functions for ranking IFVs. Lalancette et al. [16] provided a review of rank-based estimation methods for asymptotic dependence and independence in linear models. Rank-based M-estimators are proposed, and asymptotic normality is established under weak regularity conditions. Watcharotone et al. [17] developed a robust rank-based picked-point analysis optimizable for heavy-tailed or skewed distributions for the analysis of covariance with heteroscedastic slopes. is technique is compared with least-square based picked-point analyses for normal and nonnormal models by Monte Carlo simulation. Rank-based analyses appeared valid and more powerful than the least-square method over all the situations, although losing little efficiency for normal models. Kloke and McKean [18] developed R package for computing rank-based estimators and their associated inferences. is package includes a library of several score functions suitable for different shapes of error distributions and provides detailed rank analyses. Shao et al. [19] provided ordered treatment methods based on maximum likelihood and robust estimation for one-factor randomized group design including a vector of the covariate for the cluster-correlated model. e proposed estimation method produced higher power and showed robustness against outliers through theoretical and simulation results. Bindele et al. [20] proposed the estimator for rank estimation of regression coefficients in a single-index regression model. e conditions are established for consistency and asymptotic normality of the estimators. e efficiency and robustness of the rank estimator are compared with semiparametric least-square by using Monte Carlo simulation. A real-life example is used as an illustration that rank regression fixes model nonlinearity in the presence of outliers. Abebe and McKean [21] discussed the estimation of parameters in the linear regression model. ey considered the estimator which minimizes weighted Wilcoxon dispersion function and established its asymptotic properties. e robustness, efficiency, and validity of these estimates are verified over several normal and nonnormal error distributions. Terpstra and McKean [22] demonstrated robust analyses based on the calculation of weighted Wilcoxon (WW) for linear models. An R suite of function is developed for WW estimation and testing of hypotheses, diagnostic measures, and residual analysis is available. Bindele [23] considered rank estimator of the general linear regression model. e author established strong consistency of the rank estimator is under mild conditions. Abebe et al. [24] presented a rank-based fitting procedure for repeated measurement design that is based on replacing a norm based on a score function for the Euclidean norm. By using a simulation study, proposed estimators are proved efficient, asymptotically normal, and valid, also a real dataset with inherent hierarchy is used for illustration. Cerný et al. [25] studied algorithms for minimization of Jaeckel's dispersion function to reach the robust rank estimator that is insensitive to outliers. A new two-stage algorithm is developed merging the benefits of two algorithms already used in the literature, approximate and exact algorithms. e behavior of this two-stage algorithm is illustrated using a computational experiment, and convergence and exact result is achieved. Cerny et al. [26] focused on the optimization algorithms of rank estimators by dividing these in two major classes: continuous and convex objective function (CCC), and another class (GEN). For CCC unconditionally polynomial algorithm and for GEN, the enumerative algorithm is proposed that is efficient and superior to other algorithms in the literature. Dutta and Datta [27] developed rank-based weighted estimating equations appropriate for intracluster group size is informative. Additionally, an aligned rank-sum test based on covariate adjusted outcomes is constructed. e authors provided asymptotic distributions, and test-statistics of rank estimators are presented. If the informativeness is present, the significance of selecting proper weights is shown through simulation studies. e superiority and robustness of proposed method is shown in comparison to traditional mixed models in clustered data by using real-life datasets. Dutta and Datta [28] presented a novel extension of the rank-sum test for the scenario where group-specific marginal distributions are based on intracluster group size. e performance of proposed test is compared with the Wilcoxon rank-sum test and classical signed-rank test by using the simulation study of informative intracluster group size. It is observed that the proposed test maintained correct size and attained more power [27,28]. Xie et al. [29] developed a rank test based on the rank score function using functional principal component analysis. Also, asymptotic properties of the test are established under local and alternative hypotheses. e proposed test attained good size and power in the results of simulation study. e literature showed that no one still worked on the multilevel modeling when the error term follows a Weibull distribution. So, in this article, we proposed a score function for the multilevel model when the error term follows a Weibull distribution to optimize rank-based analyses. Additionally, we compared the performance of the proposed score function with the Wilcoxon score and the traditional REML method.

Description of Multilevel Model and Rank Theory
In this section, a brief overview of the random intercept multilevel model, rank theory, and optimal score function is described.

Random Intercept Model.
e multilevel models generate cluster-correlated errors due to the hierarchical structure in data and are a special case of mixed effect models. A general two-level random intercept multilevel model is defined as [30] where y j is an n j × 1 vector of responses measured at level-1 for the individual I in cluster j (i subscript refers to individuallevel variation and j refers to group-level variation), X j is the n j × p design matrix of fixed effects, and Z j is the n j × q design matrix of random effects. β is the vector of fixed effect, ε ij is the n j × 1 vector of individual-level error terms for group j, and u j is the vector of random effects for cluster j and following normal distribution, i.e., ε ij ∼ N(0, σ 2 e ) and u 0j ∼ N(0, σ 2 u ), respectively. It is assumed that the error terms follow to be independently normally distributed across individuals with distribution function F and density function f.

Brief Overview of Rank eory.
In the least-square estimation, the vector β is obtained by minimizing the Euclidean norm; similarly, rank-based estimation is accomplished by minimizing a pseudonorm. us, the robust estimate of β ϕ can be defined as [9] It is efficient and robust in Y-space (Kloke and McKean, 2012). Al-Shomrani (2003) defined this pseudonorm by where R denotes the rank of v t among v 1 , . . . , v n and these are invariant to constant shifts, y ij is the dependent variable for the individual i in a cluster j, and x ij ′ is the corresponding n j × p matrix of covariates.

Mathematical Problems in Engineering
A suitable selection of score function according to the shape of error distribution is required for optimal analysis. e score function ϕ(u) is a nondecreasing square-integrable function bounded in the interval (0, 1). e score function can be standardized such that ϕ(u)du � 0 and ϕ 2 (u)du � 1. Scores are calculated as a[t] � ϕ[(t/N + 1)], where t � 1,. . ., N, and N is the total sample size, and these scores sum equal to zero, i.e., φ e asymptotic distribution of the rank-based estimator β ϕ is defined as [13] Hence, minimizing the variance of the β ϕ is equivalent to minimizing τ ϕ . e parameter τ ϕ is given by [13] e comparison based on asymptotic relative efficiency can be obtained as (σ 2 /τ 2 ϕ ), where σ 2 is the variance of the REML estimator that is a traditional method to estimate multilevel models based on the maximization of the likelihood function.

Optimal Scores.
e rank-based analyses are based on the selection of a score function. If the underlying distribution of the error term is known, then [31] showed that the following expression can be used to derive the optimal score function as is expression calculates scores that lead to fully efficient rank-based estimates where f(u) and F(u) are probability density function (pdf ) and cumulative density function (cdf ), respectively, of the respective error distributions. Wilcoxon score function is the optimal score for the logistic distribution of the error term. e expression for the Wilcoxon score is [13], from equations (5) and (6), τ − 1 ϕ can be explained as

According to Mckean and Kloke
In the last expression, ρ is the correlation coefficient and ���� I(f) is the Fisher Information matrix. Hence, minimization of scale estimator can be achieved by maximizing (6) is a compact expression of the optimal score function. Only the knowledge about the form of f (x) is required to make the rank-based estimator β ϕ fully efficient [13].

Weibull Score Function
In this section, after presenting a brief description of the Weibull distribution, a path diagram to reach the optimal score function for the Weibull distribution is shown. is segment includes all the important steps in completing the derivation of the score function.

Proposed Score Function.
e path to propose optimal score function is briefly described in a flow diagram in Figure 1.

Weibull Error Distribution.
e Weibull distribution is a continuous right-skewed distribution. It was first identified by Fréchet in 1928 [32] and later on discussed in detail by Swedish mathematician Waloddi Weibull [33]. is distribution is extensively used in survival analysis, reliability analysis, and extreme value theory. e pdf of Weibull distribution is of the form: where k ∈ (0, ∞) and λ ∈ (0, ∞) and skewness is controlled by shape parameter typically ranges between 0.5 and 8.0. In this study, we have fixed the value of the scale parameter λ � 1 and varied the value of the shape parameter from 1.0 to 4.0, capable to change the distribution shape from skewed to symmetric. Hence, the pdf simplifies to the following form: In this article, we are concerned with the random intercept multilevel model (1), in which the level-1 and level-2 random errors follow the Weibull distribution. To develop an optimal score function for some specific value of shape parameter k , it requires only knowledge about the form of pdf.

Derivation of Score Function.
e pdf of Weibull distribution for the error term is defined by where k is the shape parameter and λ is the scale parameter. Let us assume λ � 1, then the pdf becomes f(u) � ku k− 1 e − (u) k . e quantile function of Weibull distribution for k � 1 is given by e optimal score function can be derived by the following expression: 4 Mathematical Problems in Engineering Let us assume that After substituting the value of x, e score function is e derivative of the score function is required for implementation in the R package: e plot of the score function is suitable for Weibull distribution for the shape parameter k � 1.5, 2, 3, 4 and is shown in Figure 2. e left panel comprises pdf's and the right panel displays its corresponding optimal score functions. It is noticeable that the pdf is extremely right-skewed for the smallest value k. e skewness in distribution tends to become symmetric with increasing the value of k. Hence, when the value of k � 4, then its pdf is closer to symmetric distribution.

Simulation
e simulated model is as follows: where y ij is the response variable and x ij are the explanatory variables generated from uniform distribution, i.e., x ij ∼ uniform(0, 1) measured at level-1. u 0j and e ij are random errors at the group level and individual level, respectively, simulated with weibull(k, λ � 1). e number of groups is denoted by j, and the vector y j has N � j n j observations, where n j is the number of observations. e score function is evaluated for multilevel models at different sample sizes. Level-1 sample size (N1) was taken 5, 10, 20, and 40 within each level-2 sample size (N2) 5, 10, 20, and 40 leading to the range of total sample size N � 25-1600. e simulation is repeated 1000 times on R software. e number of covariates included in the model is considered to be p � 3 and p � 6. e true regression parametric values are selected according to [13]. e efficiency of the Weibull score function ϕ 1.5 (u) is compared with the Wilcoxon score function and the traditional method REML. To assess the performance of the Weibull score function, we use bias, MSE, and precision as the performance evaluation criteria. Absolute estimation of bias for the fixed effects of covariates and the random effect c i is calculated as Bias where β is the vector of estimates. e estimates of MSE is calculated as MSE(β) � Var(β) + (Bias(β)) 2 .
ree estimates of precision are calculated by taking a ratio of scale estimators obtained by a rank-based method with Weibull score, Wilcoxon score, and REML as MSE weib /MSE REML , MSE weib /MSE wil , MSE wil /MSE REML .
Two kinds of error distributions are reflected in this simulation study: Weibull distribution and contaminated Weibull distribution.
e contaminated Weibull error model is generated as where I ε,i is a random variable with a binomial distribution (1, ε � 0.20). e W is the Weibull random error with the shape parameter k � 1, 1.5, 2.5, 4.0.V i is a random variable from Weibull distribution V i ∼ weibull(k). A similar setting is used for group-level error too. For robust analysis through rank theory, the score ϕ 1.5 (u) is selected suitable for k � 1.5 in Weibull distribution. Five values of k close to k � 1.5 are considered to show a comparative analysis of optimal score function, i.e., k � 1, 1.5, 2.5, 4.0. Table 1 and Table 2 summarize the results of the simulation study with estimated bias and MSE of β. e estimates of bias and MSE of the multilevel model including p � 3 and p � 6 covariates, when ε ∼ Weibull(1.0, 1.0), are computed through the rank-based method, Wilcoxon score function, and REML. After obtaining three estimates of precisions, it is worthy to notice that the rank-based method is most efficient than REML, either applied through Weibull or Wilcoxon score function. Auda et al. [1] debated the same results that the rank-based method is generally highly efficient even if few outliers are present in the data. e efficiency of regression estimates is many times better than MLE for skewed data. erefore, low MSE is observed for the rank-based method either applied through Wilcoxon or Weibull score function than MLE. Furthermore, the smallest bias and MSE are achieved through the Weibull score function as compared to the Wilcoxon, for β with p � 3 case. Although for p � 6 covariates, for group size 5, Weibull score is better than Wilcoxon but for group size larger than 10, Weibull and Wilcoxon are equally precise. Table 3 and Table 4 comprise the estimates of bias and MSE of β for p � 3 and p � 6 covariates in the multilevel model when ε ∼ Weibull(1.5, 1.0). It is observed that in all the simulation scenarios, Weibull score function is more efficient than the Wilcoxon score. Additionally, it is seen that REML is least efficient than rank-based estimation with Weibull and Wilcoxon score function. Table 5 and Table 6 display the estimates of bias and MSE of β for p � 3 and p � 6 covariates in the multilevel model ε ∼ Weibull(2.5, 1.0). It is observed that for p � 3 against all the sample sizes, the Weibull score function appeared more efficient than the Wilcoxon score. Additionally, it is seen that REML is least efficient than rank-based estimation with Weibull and Wilcoxon score function. However, for p � 6, both the score functions produce quite a similar fit and all three techniques are equally precise. Table 7 and Table 8 show the estimated bias and MSE of β for p � 3 and p � 6 covariates in the multilevel model ϵ ∼ Weibull(4, 1.5). It is observed that for p � 3 against all the sample sizes, the Weibull score function performed efficiently than the Wilcoxon score function. Additionally, it is seen that REML is equally efficient as rank-based estimation with Weibull and Wilcoxon score function. However, for p � 6, both the score functions produce quite a similar fit and all three techniques are almost equally precise. As the value of the shape parameter increases the distribution shape becomes symmetric, hence the Wilcoxon score function starts becoming the optimal score.     considered. e contamination model is described in (11) that is designed to include outliers and make the distribution shape more skewed. Table 9 consists of bias and MSE of β when ϵ ∼ Weibull(1.0, 1.0) with p � 3, it is obvious from estimates of precision that the Weibull score function is efficient than the Wilcoxon score function, and the rankbased method by using Wilcoxon and Weibull is far more efficient than REML. McKean and Kloke [13] compared the rank-based fit by using the skew-normal score function for skew-normal data and compared the empirical relative   In the same manner, it is observed that estimates with the Weibull score function ϕ 1.5 (u) are most efficient than for neighborhood parametric values. Also, the Weibull score function appeared most efficient than Wilcoxon and MLE. From Table 10 for p � 6, it is clear that the Weibull score is more precise than REML but Wilcoxon scores in almost equal precisely as REML. Moreover, the Weibull score is efficient than the Wilcoxon score function as it produces low estimates of bias and MSE. Table 11 comprises the estimates for p � 3 when ϵ ∼ Weibull(1.5, 1.0), and it is observed that Weibull and Wilcoxon score functions are almost equally precise. However, the rank-based method appeared efficient in some instances than REML. In Table 12, for p � 6, at three occasions of sample size, Weibull appeared efficient. REML is found precise in some combinations of level-1 and level-2 sample sizes. Table 13 displays the estimated bias and MSE of β when ϵ ∼ Weibull(2.5, 1.0) with p � 3. It is obvious that the Weibull score function computes the smallest estimates, leads to the most efficient analysis. Rank-based analysis by using the Wilcoxon score function and REML produces almost equal fit. Table 14, for p � 6, shows that Weibull score is better than Wilcoxon but in most instances, both score functions produce quite equal fit. Similar behavior is seen between the efficiency of rank-based methods and REML.      Table 15, presents the estimates of bias and MSE of β when ϵ ∼ Weibull(4.0, 1.0) with p � 3. In most of the sample sizes, the Weibull score is better than the Wilcoxon score and sometimes both techniques performed equally well. Rankbased estimation and REML are found equally precise. Table 16, for p � 6, indicates that the Weibull score is as equally efficient as the Wilcoxon score for all sample sizes. Similar behavior is seen between the efficiency of rank-based methods and REML. Both techniques produce quite a similar fit. For p � 3, the Weibull score is found efficient than Wilcoxon, whereas for p � 6, both score functions showed almost the same precision.

Real Data
Application. e dataset "CASchools" taken from [34] encloses the information on test performance, school characteristics, and student demographic backgrounds for all 420 K-6 and K-8 districts in California with data available for 1998 and 1999. e reading score is a response variable with three explanatory variables included in the model. ese include the percentage of students who are English learners (student's demographic variable), the expenditure per student spent by the school (the US $ 1,000), and the student-teacher ratio is computed by working on school characteristics. e data are analyzed to verify the simulation results because the response variable is Weibull distributed with shape (k � 2.60825) and scale parameter (λ � 6.67620). A multilevel model has been applied to these data through REML, rank-based method with Wilcoxon, and Weibull score functions. e estimates of fixed effects, SE, and p value are summarized in Table 17.
As the number of students who are English learners (English is not their first language) increases, the average score on reading declines significantly. e improvement in

Conclusion
We proposed a score function of the rank-based estimation for the multilevel model when the error terms follow the Weibull distribution. To reach the optimal analysis, we compared the performance of Weibull and Wilcoxon score functions with the traditional method REML through a   simulation study and a real application. A random intercept multilevel model is analyzed by a rank-based method including three and six covariates for level-1 and level-2 sample sizes under Weibull and contaminated Weibull distributed error terms. e estimates of bias, MSE, and precision of three methods, i.e., Weibull, Wilcoxon, and REML, are computed for each simulation scenario. For estimates of β with p � 3, the Weibull score function is found to be more precise as compared to the Wilcoxon score for k � 1.0, 1.5, 2.5, 4.0, whereas for p � 6, both score functions showed the same precision. e REML is appeared least efficient among all three methods for all simulation scenarios. Similarly, for contaminated Weibull distribution with k � 1.0, 1.5, 2.5, 4.0, quite similar behavior is observed. For p � 3, the Weibull score function is mostly efficient than the Wilcoxon score function whereas for p � 6, both score functions show equal efficiency. For a small value of k, the Weibull score function is performed as the most efficient estimation method because the distribution shows the skewed shape. On the other hand, for large values of k, the Wilcoxon score function outperformed due to the closed symmetric shape. Moreover, real application results also show that the Weibull score function produces a smaller variation as compared to the Wilcoxon score and REML methods.

Limitations and Future Recommendations
Limitations: Weibull score function is derived only for the Weibull distribution of the error term. It is derived for the cluster-correlated error term in linear models. In this study, the Weibull score function is applied to analyze the random intercept multilevel models only.
Future recommendations: the side versions of the Weibull score function could be derived for special cases of Weibull distributions. It could be derived for other dependent error structures like in the time-series AR (1) model of error terms. Its application could be made valid for random intercept and random slope multilevel models.

Data Availability
No data were used to support the findings of this study.

Conflicts of Interest
e authors declare that they have no conflicts of interest.