There exist many iterative methods for computing the maximum likelihood estimator but most of them suffer from one or several drawbacks such as the need to inverse a Hessian matrix and the need to find good initial approximations of the parameters that are unknown in practice. In this paper, we present an estimation method without matrix inversion based on a linear approximation of the likelihood equations in a neighborhood of the constrained maximum likelihood estimator. We obtain closed-form approximations of solutions and standard errors. Then, we propose an iterative algorithm which cycles through the components of the vector parameter and updates one component at a time. The initial solution, which is necessary to start the iterative procedure, is automated. The proposed algorithm is compared to some of the best iterative optimization algorithms available on R and MATLAB software through a simulation study and applied to the statistical analysis of a road safety measure.
Approximation methods for Maximum Likelihood (ML) systems of equations are of interest and are motivated in this paper by the need to find estimation methods that are simple and easy to implement in the specific field of the statistical evaluation of the impact of a road safety measure. In practice, the estimation methods dedicated to this evaluation depend both on the nature of the measure and the available data. Methods based on frequencies combination have received considerable attention [
Many approximation methods for maximum likelihood estimation need to solve systems of linear or non-linear equations with or without constraints [
ϕ ( k + 1 ) = ϕ ( k ) + [ M ( ϕ ( k ) ) ] − 1 ∇ l ( ϕ ( k ) ) (1)
where ϕ ( k ) is the estimate of the vector parameter at the step k , l is the log-likelihood function, ∇ l ( ϕ ( k ) ) is the gradient of l and M ( ϕ ( k ) ) is the observed or the expected information matrix. Both methods require the com- putation of second-order partial derivatives and a matrix inversion in each iteration, which can be very costly. Some authors such as Wang [
Within the framework of crash data analysis, different iterative estimation methods have been proposed [
Despite the above advantages, the choice of the starting value ϕ ( 0 ) remains a major issue since a value of ϕ ( 0 ) relatively far from the true unknown value of the vector parameter can lead to erroneous solutions or to non-convergence. In addition to this, it must be noted that obtaining explicit expressions of standard errors is not generally easy.
In this paper, we present an estimation method without matrix inversion based on a linear approximation of the likelihood equations in a neighborhood of the constrained maximum likelihood estimator. We obtain closed-form ap- proximations of solutions and standard errors. Then, we propose a partial linear approximation (PLA) algorithm which cycles through the components of the vector parameter and updates one component at a time. The initial solution is automated and standard errors are obtained in a closed-form. The PLA is com- pared to some of the best available algorithms on R and MATLAB software through a simulation study and applied to real crash data.
The remainder of the paper is organized as follows. Section 2 is devoted to the statistical model and the main assumptions used to get closed-form appro- ximations and standard errors. The proposed estimation method and the method for computing standard errors are presented in Section 3. The general framework of the proposed algorithm is also described. In Section 4, we give an illustration of our results using a crash data model. The numerical performance of the proposed algorithm is examined in Section 5 through a simulation study while a real-data application is given in Section 6. The appendix is devoted to the technical details of the main results.
Let Y = ( Y 11 , ⋯ , Y 1 r , Y 21 , ⋯ , Y 2 r ) be a random vector with 2 r ( r > 1 ) compo- nents and π ( ϕ ) = ( π 11 ( ϕ ) , ⋯ , π 1 r ( ϕ ) , π 21 ( ϕ ) , ⋯ , π 2 r ( ϕ ) ) be a vector of pro- babilities such that
∑ i = 1 2 ∑ j = 1 r π i j ( ϕ ) = 1
where ϕ is a parameter vector. It is assumed that the vector Y has the multinomial distribution M ( n ; π ( ϕ ) ) where n > 0 is a known integer. The basic principle of the multinomial distribution M ( n ; π ( ϕ ) ) consists in dis- tributing n items in 2 r categories or classes ( 2 r being the number of com- ponents of vector π ( ϕ ) ). The probability for an object to fall in a class is called class probability with the sum of all class probabilities equal to 1. Here, the class probabilities π i j ( ϕ ) depend on the unknown vector parameter ϕ .
Given a vector of integers y = ( y 11 , ⋯ , y 1 r , y 21 , ⋯ , y 2 r ) such that
∑ i = 1 2 ∑ j = 1 r y i j = n ,
the probability function related to M ( n ; π ( ϕ ) ) is defined by
f ( y ) = n ! ∏ i = 1 r ∏ j = 1 2 y i j ! ∏ i = 1 r ∏ j = 1 2 ( π i j ( ϕ ) ) y i j . (2)
Assumption 1. The vector parameter ϕ is partitioned as ϕ = ( θ , β ) where θ > 0 is a real parameter, β = ( β 1 , ⋯ , β r ) T is a vector and β j > 0 for all j = 1 , ⋯ , r .
Assumption 2. The unknown vector ϕ is subject to a linear constraint C ( ϕ ) = 0 where C is a continuously differentiable function from ℝ r + 1 to ℝ .
Let y = ( y 11 , ⋯ , y 1 r , y 21 , ⋯ , y 2 r ) ∈ ℝ 2 r be a vector of observed data and l ( ϕ ) be the logarithm of the probability density function f ( y ) defined by Equation (2). The constrained maximum likelihood estimator ϕ ^ = ( θ ^ , β ^ ) , is solution to the optimization problem
Maximize l ( ϕ ) subjetto C ( ϕ ) = 0. (3)
Problem (3) is equivalent to the maximization of function
L ( ϕ , λ ) = l ( ϕ ) − λ C ( ϕ ) (4)
where λ is the Lagrange multiplier. The information matrix linked to the constrained maximum likelihood estimator ϕ ^ is
Γ ϕ = [ J ϕ C ϕ T C ϕ 0 ] , J ϕ = [ τ ϕ U ϕ T U ϕ B ϕ ] (5)
where C ϕ = ( ∂ C / ∂ θ , ∂ C / ∂ β 1 , ⋯ , ∂ C / ∂ β r ) T ∈ ℝ 1 + r , J ϕ ∈ ℝ 1 + r × ℝ 1 + r ,
τ ϕ = E ( − ∂ 2 l ∂ θ 2 ) ∈ ℝ , U ϕ = E ( − ∂ 2 l ∂ θ ∂ β 1 , ⋯ , − ∂ 2 l ∂ θ ∂ β r )
and B ϕ is a r × r matrix whose entries are E ( − ∂ 2 l / ∂ β m ∂ β j ) , m , j = 1 , ⋯ , r . We also assume that the following conditions are verified:
Assumption 3. ∂ C / ∂ θ = 0 and 〈 C β , β 〉 = κ ≠ 0 where 〈 .,. 〉 is the inner product, κ is a constant and C β = ( ∂ C / ∂ β 1 , ⋯ , ∂ C / ∂ β r ) T ∈ ℝ r ;
Assumption 4. For any θ > 0 , there exists a non-singular r × r matrix Ω θ ^ , y such that C β ^ T Ω θ ^ , y − 1 C β ^ > 0 and the non-linear system
( ∂ l ∂ β ) ϕ ^ − 〈 β ^ , ( ∂ l ∂ β ) ϕ ^ 〉 〈 β ^ , C β ^ 〉 C β ^ = 0 r
is approximated by the linear system
[ Ω θ ^ , y C β ^ C β ^ T 0 ] [ β ^ 0 ] = [ D y κ ]
where 0 r = ( 0 , ⋯ , 0 ) T ∈ ℝ r and D y is a r × 1 vector whose components are obtained from y .
Assumption 5. There exists a function g : ℝ r − 1 → ℝ such that the equation
( ∂ l ∂ θ ) ϕ ^ = 0 is equivalent to θ ^ = g ( β ^ ) .
Assumption 6. There exist two strictly positive real numbers a n , ϕ and b n , ϕ , a non-singular r × r diagonal matrix Σ ϕ and a vector V ϕ ∈ ℝ r such that τ ϕ = a n , ϕ − 1 b n , ϕ 2 , B ϕ = a n , ϕ ( Σ ϕ + V ϕ V ϕ T ) and U ϕ = b n , ϕ V ϕ .
Assumption 3 specifies the form of function C . Particularly, C is only a function of sub-vector β . Assumptions 4 and 5 enable us to get β ^ from θ ^ and inversely. Assumption 6 enables us to transform the Fisher information matrix in order to use classical results on matrix inversion with Schur’s com- plement [
The general problem of finding the constrained maximum likelihood estimator has been discussed by many authors [
Lemma 1. The constrained maximum likelihood estimator ϕ ^ , provided it exists, is solution to the non-linear system
( ∂ l ∂ θ ) ϕ ^ = 0 and ( ∂ l ∂ β ) ϕ ^ − 〈 β ^ , ( ∂ l ∂ β ) ϕ ^ 〉 〈 β ^ , C β ^ 〉 C β ^ = 0 r (6)
where 0 r = ( 0 , ⋯ , 0 ) T ∈ ℝ r .
Our approach consists in dividing Equation (6) into two parts: one con- cerning the first component of ϕ ^ and the other one concerning the sub-vector β ^ .
Theorem 1. Under assumptions 3 - 5, the constrained MLE ϕ ^ = ( θ ^ , β ^ ) is given by:
θ ^ = g ( β ^ )
β ^ = Ω θ ^ , y − 1 D y .
The non-obvious part of the proof consists in the determination of β ^ by inverting the ( r + 1 ) × ( r + 1 ) matrix linked to the linear system in Assumption 4. This result based on the inversion of partitioned matrices will not be demonstrated in this paper. We refer the reader to classical papers on Schur complement [
From Theorem 1, it is seen that the MLE ϕ ^ = ( θ ^ , β ^ ) is a fixed point of the function from ℝ r + 1 to itself defined by ( θ , β ) ↦ ( g ( β ) , Ω θ , y − 1 D y ) . We can then build an iterative algorithm to estimate ϕ . The classical fixed point method which consists in simultaneously updating θ ^ and β ^ may be hard to im- plement because of the link between θ ^ and β ^ . We propose instead to alternate between updating θ ^ holding β ^ fixed and vice-versa. Starting from a given θ ( 0 ) , we compute β ( 0 ) and then θ ( 1 ) and β ( 1 ) and so on. The process is repeated until a stopping criteria is satisfied. For example, we can stop the iterations when successive values of the log-likelihood satisfy the condition | l ( ϕ ( k + 1 ) ) − l ( ϕ ( k ) ) | < ϵ where ϵ > 0 .
The estimation process may be completed by the computation of standard errors with Theorem 2 below.
Theorem 2. Under assumptions 3 - 6, the asymptotic variance of the com- ponents of ϕ ^ are
σ ^ 2 ( θ ^ ) = a n , ϕ ^ b n , ϕ ^ − 2 ( 1 + ‖ V ϕ ^ ‖ Σ ϕ ^ − 1 2 − ‖ C β ^ ‖ Σ ϕ ^ − 1 − 2 ξ ϕ ^ 2 ) (7)
and
σ ^ 2 ( β ^ j ) = a n , ϕ ^ − 1 ( Σ ϕ ^ , j − 1 − ‖ C β ^ ‖ Σ β ^ − 1 − 2 × ( Σ ϕ ^ , j − 1 × C β ^ , j ) 2 ) , j = 1 , ⋯ , r (8)
where ξ ϕ = V ϕ T Σ ϕ − 1 C β > 0 and the real values Σ ϕ , j − 1 (resp. C β , j ), j = 1 , ⋯ , r , are the diagonal elements (resp. components) of matrix Σ ϕ − 1 (resp. of vector C β ).
The proof is given in the appendix. It stems from the results of N'Guessan and Langrand [
Algorithm 1 (The partial linear approximation algorithm).
Step 0 (Initialization) Given θ ( 0 ) , ϵ > 0 , D y , compute β ( 0 ) = Ω θ ( 0 ) , y − 1 D y .
Step 1 (Loop for computing ϕ ^ ) For a given k ≥ 0 ,
a) Compute θ ( k + 1 ) = g ( β ( k ) ) and β ( k + 1 ) = Ω θ ( k + 1 ) , y − 1 D y .
b) If | l ( ϕ ( k + 1 ) ) − l ( ϕ ( k ) ) | ≥ ϵ , then replace k by k + 1 and return to Step 1.
Else, set θ ^ = θ ( k + 1 ) , β ^ = β ( k + 1 ) and go to Step 2.
Step 2 (Computation of standard errors)
a) Compute σ ^ 2 ( θ ^ ) = a n , ϕ ^ b n , ϕ ^ − 2 ( 1 + ‖ V ϕ ^ ‖ Σ ϕ ^ − 1 2 − ‖ C β ^ ‖ Σ ϕ ^ − 1 − 2 ξ ϕ ^ 2 ) .
b) For j = 1 , ⋯ , r , compute σ ^ 2 ( β ^ j ) = a n , ϕ ^ − 1 ( Σ ϕ ^ , j − 1 − ‖ C β ^ ‖ Σ β ^ − 1 − 2 × ( Σ ϕ ^ , j − 1 × C β ^ , j ) 2 ) .
The aim of this paper is not to conduct a theoretical study of the convergence of the proposed algorithm. We rather focus on the numerical aspect of this convergence through an application model. Nevertheless, we can notice that the estimation of ϕ ^ using our algorithm does not require any matrix inversion. It is thus easy to think that getting the constrained maximum likelihood estimator ϕ ^ is improved in terms of computation time.
We apply the above algorithm to estimate the parameters of a statistical model used to assess the effect of a road safety measure applied to an experimental site presenting r > 0 mutually exclusive accident types (fatal accidents, seriously injured people, slightly injured people, material damage, etc ⋯ ) over a fixed period. Let us consider the random vector Y = ( Y 11 , ⋯ , Y 1 r , Y 21 , ⋯ , Y 2 r ) where Y 1 j and Y 2 j ( j = 1 , ⋯ , r ) respectively represent the number of accidents of type j registered on the experimental site before and after the application of the road safety measure. In order to take into account some external factors (such as traffic flow, speed limit variation, weather conditions, regression to the mean effect, etc ⋯ ), the experimental site is linked to a control area where the safety measure was not directly applied. The accidents data for the control area over the same period is given by the non-random vector Z = ( z 1 , ⋯ , z r ) T where z j denotes the ratio of the number of accidents of type j registered in the period after to the number of accidents of type j registered in the period before. Following N’Guessan et al. [
Y ∼ M ( n , π ( ϕ ) )
where n is the total number of crashes recorded at the experimental site and π = ( π 11 , ⋯ , π 1 r , π 21 , ⋯ , π 2 r ) is a vector of class probabilities whose components are
π i j ( ϕ ) = ( β j 1 + θ ∑ m = 1 r z m β m if i = 1 ; j = 1 , ⋯ , r θ β j ∑ m = 1 r z m β m 1 + θ ∑ m = 1 r z m β m if i = 2 ; j = 1 , ⋯ , r . (9)
By construction, the parameter vector ϕ = ( θ , β ) of this model satisfies the conditions θ > 0 , β j > 0 and the linear constraint
C ( ϕ ) = 0 , with C ( ϕ ) = 〈 1 r , β 〉 − 1 (10)
where 1 r = ( 1 , ⋯ , 1 ) ∈ ℝ r . The scalar θ denotes the unknown parameter average effect of the road safety measure while each β j ( j = 1 , ⋯ , r ) denotes the risk of having an accident of type j on a site having the same characteristics as the experimental site. This model is a special case of the multinomial model proposed by N’Guessan et al. [
The log-likelihood is specified up to an additive constant by
l ( ϕ ) = ∑ m = 1 r [ y . m log ( β m ) + y 2 m log ( θ ) − y . m log ( 1 + θ ∑ j = 1 r z j β j ) + y 2 m log ( ∑ j = 1 r z j β j ) ] (11)
where y . m = y 1 m + y 2 m . Different iterative methods can be used to compute the constrained MLE ϕ ^ . Most of them look for stationary points of the Lagrangian
L ( ϕ , λ ) = l ( ϕ ) − λ ( ∑ m = 1 r β m − 1 ) .
N'Guessan et al. [
{ ∑ m = 1 r ( y 2 m − y . m θ ^ E ^ ( Z ) 1 + θ ^ E ^ ( Z ) ) = 0 y . j − n β ^ j ( 1 + θ ^ z j ) 1 + θ ^ E ^ ( Z ) − y 2. β ^ j ( E ^ ( Z ) − z j ) E ^ ( Z ) = 0 , j = 1 , ⋯ , r θ ^ > 0 , β ^ j > 0 , j = 1 , ⋯ , r (12)
where y 2. = ∑ m = 1 r y 2 m and E ^ ( Z ) = ∑ m = 1 r β ^ m z m .
The main idea proposed in this paper consists in neglecting the term [ y 2. β ^ j ( E ^ ( Z ) − z j ) ] / E ^ ( Z ) so that we can write the remaining equations
y . j − n β ^ j ( 1 + θ ^ z j ) 1 + θ ^ E ^ ( Z ) = 0 , j = 1 , ⋯ , r
as the linear system of equations
Ω θ ^ , y β ^ = D y (13)
where Ω θ ^ , y = M θ ^ − θ ^ D y Z T , M θ ^ = diag ( 1 + θ ^ z 1 , ⋯ , 1 + θ ^ z r ) is a diagonal r × r matrix and
D y = ( y 11 + y 21 n , ⋯ , y 1 r + y 2 r n ) T ∈ ℝ r .
Drawing our inspiration from the work by N'Guessan [
( 1 − θ ^ Z T M θ ^ − 1 D y ) = 1 − 1 n ∑ m = 1 r θ ^ z m y ⋅ m 1 + θ ^ z m .
The components of the constrained MLE ϕ ^ can then be computed as follows.
Corollary 1. The components of ϕ ^ = ( θ ^ , β ^ ) are given by
θ ^ = ∑ m = 1 r y 2 m ( ∑ m = 1 r β ^ m z m ) × ( ∑ m = 1 r y 1 m ) (14)
β ^ j = 1 1 − Δ n ( θ ^ ) × 1 1 + θ ^ z j × y . j n , j = 1 , ⋯ , r (15)
where Δ n ( θ ^ ) = 1 n ∑ m = 1 r θ ^ z m y ⋅ m 1 + θ ^ z m .
Applying Theorem 2’s results, we can give the asymptotic variance of the constrained MLE ϕ ^ .
Corollary 2. The asymptotic variance of the components of the constrained maximum likelihood estimator ϕ ^ is given by
σ ^ 2 ( θ ^ ) = 1 n E ^ ( Z ) θ ^ + 1 n ( 1 + E ^ ( Z 2 ) ( E ^ ( Z ) ) 2 ) θ 2 + E ^ ( Z ) n θ 3 (16)
σ ^ 2 ( β ^ j ) = 1 n β ^ j ( 1 − β ^ j ) , j = 1 , ⋯ , r (17)
where E ^ ( Z ) = ∑ m = 1 r β ^ m z m and E ^ ( Z 2 ) = ∑ m = 1 r β ^ m z m 2 .
Technical proof uses the Schur complement approach and stems from [
C ϕ = ( 0 , 1 , ⋯ , 1 ) T ∈ ℝ 1 + r , τ ϕ = γ 2 E ( Z ) n θ , U ϕ = γ 2 n Z , B ϕ = γ ( Σ ϕ + V ϕ V ϕ T ) (18)
where
V ϕ = ( θ γ n E ( Z ) ) 1 / 2 Z , Σ ϕ = n γ × diag ( 1 β 1 , ⋯ , 1 β r ) , γ = n 1 + θ E ( Z ) . (19)
Setting a n , ϕ = γ and b n , ϕ 2 = ( γ 3 E ( Z ) ) / ( n θ ) , we show that Assumption 6 is satisfied. We then apply Theorem 2 to get the results of Corollary 2.
Algorithm 2.
Step 0 (Initialization) Given ϵ > 0 and D y , set θ ( 0 ) = 0 and compute β ( 0 ) = D y .
Step 1 (Loop for computing ϕ ^ ) For a given k ≥ 0 ,
a) Compute θ ( k + 1 ) = ∑ m = 1 r y 2 m ( ∑ m = 1 r β m ( k ) z m ) × ( ∑ m = 1 r y 1 m )
b) For j = 1 , ⋯ , r , compute
β j ( k + 1 ) = 1 1 − 1 n ∑ m = 1 r θ ( k + 1 ) z m y . m 1 + θ ( k + 1 ) z m × 1 1 + θ ( k + 1 ) z j × y . j n .
c) If | l ( ϕ ( k + 1 ) ) − l ( ϕ ( k ) ) | ≥ ϵ , then replace k by k + 1 and return to Step 1.
Else, set θ ^ = θ ( k + 1 ) , β ^ = β ( k + 1 ) and go to Step 2.
Step 2 (Computation of standard errors)
a) Compute σ ^ 2 ( θ ^ ) = 1 n E ^ ( Z ) θ ^ + 1 n ( 1 + E ^ ( Z 2 ) ( E ^ ( Z ) ) 2 ) θ 2 + E ^ ( Z ) n θ 3 .
b) For j = 1 , ⋯ , r , compute σ ^ 2 ( β ^ j ) = 1 n β ^ j ( 1 − β ^ j ) .
The partial linear approximation algorithm for computing the constrained maximum likelihood estimator ϕ ^ of the model presented in subsection 4.1 stems from the cyclic algorithm of N’Guessan and Geraldo [
We can also note that the second partial derivatives of the log-likelihood function are no longer used in our algorithm. The aim of this paper is not to carry out a theoretical study of the convergence of the proposed algorithm. We rather focus on the numerical aspect of this convergence using simulated datasets.
For a given value of r (the number of crash types), we generate the com-
ponents of vector Z = ( z 1 , ⋯ , z r ) T from a uniform random variable U ( 1 2 , 5 2 ) .
The true value of θ denoted θ 0 is fixed and the true value of β , denoted β 0 = ( β 1 0 , ⋯ , β r 0 ) T , such that ∑ j = 1 r β j 0 = 1 , comes from a uniform random variable U ( ϵ , 1 − ϵ ) where ϵ = 10 − 5 . Using those values, we compute the true probabilities
π 1 j ( ϕ 0 ) = β j 0 1 + θ 0 ∑ m = 1 r z m β m 0 , π 2 j ( ϕ 0 ) = θ 0 β j 0 ∑ m = 1 r z m β m 0 1 + θ 0 ∑ m = 1 r z m β m 0 , j = 1 , ⋯ , r
linked to the multinomial distribution presented in subsection 4.1. Finally, one generates the total number n of crash data from a Poisson distribution and then randomly shares it between the before and after periods using probabilities π 1 j ( ϕ 0 ) and π 2 j ( ϕ 0 ) . The observed values of y i j such that ∑ i = 1 2 ∑ j = 1 r y i j = n are then found.
This subsection deals with the numerical convergence of the partial linear approximation algorithm. As usual in the study of iterative algorithms, we analyse the influence of the initial solution ϕ ( 0 ) = ( θ ( 0 ) , β ( 0 ) ) , the number of iterations, the computation time (CPU time) and the mean squared error. The performances of the partial linear approximation algorithm are compared to those of some classical optimization methods available in R and MATLAB software. The computations presented in this section were executed on a PC with an AMD E-350 Processor 1.6 GHz CPU.
The methods selected for comparison are the Newton-Raphson’s method, Nelder-Mead’s (NM) simplex algorithm [
The simulation process was performed on many simulated crash datasets. For each one, small and large values of n were considered. The results presented here correspond to the case r = 3 , n ∈ { 50 ; 5000 } , ϕ 0 = ( θ 0 , β 0 ) with θ 0 = 0.6 and β 0 = ( 0.025 , 0.232 , 0.743 ) .
Three different ways of setting β ( 0 ) were considered:
1) Uniform initialisation: β 1 ( 0 ) = β 2 ( 0 ) = ⋯ = β r ( 0 ) = 1 / r .
2) Proportional initialisation: β j ( 0 ) = y 1 j + y 2 j n , j = 1 , ⋯ , r .
3) Random initialisation: for j = 1 , ⋯ , r , β j ( 0 ) = u j / ( ∑ i = 1 r u i ) where each
u i ( i = 1 , ⋯ , r ) is randomly generated from an uniform distribution U ( 0.05 , 0.95 ) .
By combining the two values of n and the three ways to initialize β ( 0 ) , we get six scenarios and for each one, we performed 1000 replications. The stopping criterion is the condition | l ( ϕ ( k + 1 ) ) − l ( ϕ ( k ) ) | < 10 − 5 .
Tables 1-6 present a few of the results obtained for an overall 6000 simu- lations. All computation times are given in seconds and the duration ratio of an
R software | MATLAB software | |||||||
---|---|---|---|---|---|---|---|---|
PLA | NR | BFGS | NM | PLA | LM | TR | IP | |
0.621 | 0.617 | 0.617 | 0.618 | 0.643 | 0.639 | 0.639 | 0.639 | |
0.060 | 0.054 | 0.054 | 0.054 | 0.060 | 0.054 | 0.054 | 0.054 | |
0.207 | 0.227 | 0.227 | 0.227 | 0.203 | 0.223 | 0.223 | 0.223 | |
0.733 | 0.719 | 0.719 | 0.719 | 0.737 | 0.723 | 0.723 | 0.723 | |
Min. iterations | 2 | 2 | 11 | 8 | 2 | 3 | 2 | 8 |
Max. iterations | 4 | 4 | 11 | 19 | 4 | 4 | 11 | 22 |
Mean iterations | 3.1 | 3.0 | 11.0 | 12.1 | 3.1 | 3.2 | 5.8 | 13.8 |
CPU time | 7.64E−04 | 3.84E−03 | 1.83E−01 | 2.85E−01 | 1.41E−03 | 4.37E−02 | 5.07E−02 | 4.97E−01 |
Duration ratio | 1 | 5 | 239 | 373 | 1 | 31 | 36 | 353 |
MSE | 9.90E−03 | 9.74E−03 | 9.74E−03 | 9.79E−03 | 1.12E−02 | 1.09E−02 | 1.09E−02 | 1.09E−02 |
R software | MATLAB software | |||||||
---|---|---|---|---|---|---|---|---|
PLA | NR | BFGS | NM | PLA | LM | TR | IP | |
0.604 | 0.601 | 0.601 | 0.602 | 0.604 | 0.601 | 0.601 | 0.601 | |
0.028 | 0.025 | 0.025 | 0.025 | 0.028 | 0.025 | 0.025 | 0.025 | |
0.212 | 0.232 | 0.232 | 0.233 | 0.212 | 0.232 | 0.232 | 0.232 | |
0.760 | 0.743 | 0.743 | 0.742 | 0.760 | 0.743 | 0.743 | 0.743 | |
Min. iterations | 4 | 3 | 15 | 12 | 4 | 3 | 3 | 9 |
Max. iterations | 4 | 4 | 15 | 20 | 4 | 4 | 12 | 21 |
Mean iterations | 4.0 | 3.3 | 15.0 | 15.1 | 4.0 | 3.0 | 6.4 | 13.7 |
CPU time | 9.35E−04 | 4.11E−03 | 3.23E−01 | 3.54E−01 | 1.71E−03 | 4.24E−02 | 5.30E−02 | 5.33E−01 |
Duration ratio | 1 | 4 | 345 | 379 | 1 | 25 | 31 | 311 |
MSE | 2.82E−04 | 9.62E−05 | 9.62E−05 | 1.18E−04 | 2.77E−04 | 9.24E−05 | 9.24E−05 | 9.24E−05 |
R software | MATLAB software | |||||||
---|---|---|---|---|---|---|---|---|
PLA | NR | BFGS | NM | PLA | LM | TR | IP | |
0.626 | 0.622 | 0.622 | 0.623 | 0.632 | 0.628 | 0.628 | 0.628 | |
0.061 | 0.055 | 0.055 | 0.055 | 0.060 | 0.053 | 0.053 | 0.053 | |
0.206 | 0.226 | 0.226 | 0.226 | 0.205 | 0.226 | 0.226 | 0.226 | |
0.733 | 0.720 | 0.720 | 0.719 | 0.735 | 0.721 | 0.721 | 0.721 | |
Min. iterations | 3 | 2 | 11 | 8 | 3 | 2 | 2 | 6 |
Max. iterations | 3 | 3 | 11 | 19 | 3 | 3 | 13 | 20 |
Mean iterations | 3.0 | 2.9 | 11.0 | 12.0 | 3.0 | 3.0 | 6.1 | 11.5 |
CPU time | 7.11E−04 | 3.75E−03 | 1.85E−01 | 2.81E−01 | 1.30E−03 | 4.26E−02 | 5.14E−02 | 4.99E−01 |
Duration ratio | 1 | 5 | 260 | 395 | 1 | 33 | 39 | 383 |
MSE | 1.00E−02 | 9.86E−03 | 9.86E−03 | 9.84E−03 | 1.15E−02 | 1.13E−02 | 1.13E−02 | 1.13E−02 |
R software | MATLAB software | |||||||
---|---|---|---|---|---|---|---|---|
PLA | NR | BFGS | NM | PLA | LM | TR | IP | |
0.604 | 0.601 | 0.660 | 0.662 | 0.604 | 0.601 | 0.601 | 0.601 | |
0.028 | 0.025 | 0.025 | 0.026 | 0.028 | 0.025 | 0.025 | 0.025 | |
0.211 | 0.232 | 0.232 | 0.233 | 0.211 | 0.232 | 0.232 | 0.232 | |
0.760 | 0.743 | 0.743 | 0.742 | 0.760 | 0.743 | 0.743 | 0.743 | |
Min. iterations | 4 | 2 | 1 | 1 | 4 | 2 | 2 | 3 |
Max. iterations | 4 | 3 | 15 | 21 | 4 | 3 | 12 | 20 |
Mean iterations | 4.0 | 2.9 | 14.6 | 14.7 | 4.0 | 3.0 | 6.3 | 12.5 |
CPU time | 9.20E−04 | 3.69E−03 | 3.10E−01 | 3.47E−01 | 1.59E−03 | 4.19E−02 | 5.21E−02 | 5.31E−01 |
Duration ratio | 1 | 4 | 337 | 378 | 1 | 26 | 33 | 334 |
MSE | 2.76E−04 | 8.96E−05 | 5.17E−02 | 5.16E−02 | 2.82E−04 | 9.30E−05 | 9.30E−05 | 9.30E−05 |
algorithm is defined as the ratio between the mean computation time of this latter and the mean computation time of the PLA (therefore the duration ratio of the partial linear approximation algorithm always equals 1). The computation time depends on the computer used to perform the simulations while the duration ratio is computer-free and therefore more useful.
To analyse the convergence, we used the mean squared error (MSE) defined as:
R software | MATLAB software | |||||||
---|---|---|---|---|---|---|---|---|
PLA | NR | BFGS | NM | PLA | LM | TR | IP | |
0.639 | 0.635 | 0.932 | 0.939 | 0.632 | 0.628 | 0.628 | 0.628 | |
0.060 | 0.053 | 0.094 | 0.065 | 0.060 | 0.054 | 0.054 | 0.054 | |
0.205 | 0.226 | 0.243 | 0.247 | 0.204 | 0.224 | 0.224 | 0.224 | |
0.735 | 0.721 | 0.663 | 0.688 | 0.736 | 0.722 | 0.722 | 0.722 | |
Min. iterations | 2 | 2 | 1 | 1 | 2 | 3 | 3 | 8 |
Max. iterations | 4 | 4 | 11 | 20 | 4 | 4 | 12 | 22 |
Mean iterations | 3.4 | 3.1 | 9.5 | 10.5 | 3.4 | 3.4 | 5.9 | 13.5 |
CPU time | 7.76E−04 | 3.92E−03 | 1.60E−01 | 2.75E−01 | 1.39E−03 | 4.29E−02 | 4.96E−02 | 4.95E−01 |
Duration ratio | 1 | 5 | 207 | 354 | 1 | 31 | 36 | 357 |
MSE | 1.16E−02 | 1.13E−02 | 2.52E−01 | 2.47E−01 | 1.08E−02 | 1.05E−02 | 1.05E−02 | 1.05E−02 |
R software | MATLAB software | |||||||
---|---|---|---|---|---|---|---|---|
PLA | NR | BFGS | NM | PLA | LM | TR | IP | |
0.603 | 0.600 | 0.839 | 0.841 | 0.603 | 0.600 | 0.600 | 0.600 | |
0.028 | 0.025 | 0.067 | 0.036 | 0.028 | 0.025 | 0.025 | 0.025 | |
0.211 | 0.232 | 0.244 | 0.252 | 0.211 | 0.232 | 0.232 | 0.232 | |
0.760 | 0.743 | 0.689 | 0.712 | 0.760 | 0.743 | 0.743 | 0.743 | |
Min. iterations | 3 | 2 | 1 | 1 | 3 | 3 | 3 | 8 |
Max. iterations | 4 | 4 | 15 | 20 | 4 | 4 | 12 | 31 |
Mean iterations | 4.0 | 3.4 | 13.2 | 13.4 | 4.0 | 3.4 | 6.5 | 14.1 |
CPU time | 8.55E−04 | 4.40E−03 | 2.84E−01 | 3.31E−01 | 1.58E−03 | 4.30E−02 | 5.40E−02 | 5.34E−01 |
Duration ratio | 1 | 5 | 332 | 387 | 1 | 27 | 34 | 338 |
MSE | 2.80E−04 | 9.40E−05 | 1.85E−01 | 1.75E−01 | 2.81E−04 | 9.55E−05 | 9.55E−05 | 9.55E−05 |
MSE ( ϕ ^ , ϕ 0 ) = 1 1 + r ( ( θ ^ − θ 0 ) 2 + ∑ j = 1 r ( β ^ j − β j 0 ) 2 ) (20)
One can see that the MSE decreases when n (the total number of road crashes) increases. The PLA is at least as efficient as the other algorithms. It always converges to reasonable and acceptable parameter vector estimates and the estimate gets closer to the the true value as n increases.
For a small value of n (see
When n increases ( n = 5000 ) , the MSE of the PLA decreases from 10 − 2 to 10 − 4 . So the PLA is also efficient. Unsurprisingly, when n is very great the estimates produced by the other algorithms are closer to the true values than those of the PLA. This is expected because the other algorithms work with the exact gradient. However, the Nelder-Mead’s and BFGS algorithms produce estimates very far from the truth. Their MSE’s order is 10 − 2 (
To analyse the influence of the initial guess, we considered the mean number of iterations and the amplitude of the iterations (i.e. difference between the maximum and the minimum number of iterations). An increase in the am- plitude of iterations suggests a greater influence of the initial solution ϕ ( 0 ) . The results given in Tables 1-6 suggest that the PLA is stable and robust to initial guesses of the parameter being estimated. For the 6000 replications, the number of iterations needed by the PLA to converge lies between 2 and 4. In other words, setting the initial guess to 6000 different values chosen in the parameter vectors space does not disturb the PLA. This performance is as good as those of Newton- Raphson and Levenberg-Marquardt and by far better than those of BFGS, Nelder-Mead’s and Interior Point which have their number of iterations varying respectively from 1 to 15, 1 to 21 and 3 to 31.
As far as the computation time is concerned, it can be noticed that all the CPU time ratio are greater than 1 which means that none of the compared algorithms is faster than the PLA. On average, the PLA is 4 to 5 times quicker than Newton-Raphson, 239 to 345 times quicker than BFGS algorithm, 354 to 395 times quicker than Nelder-Mead, 27 to 31 times quicker than Levenberg- Marquardt, 33 to 39 times quicker than Trust region algorithms and 311 to 383 times quicker than Interior point algorithms. This can be an important factor when larger values of r are considered.
We apply the partial linear approximation algorithm to the data concerning the changes applied to road markings on a rural Nord Pas-de-Calais road (France) [
Note that the number of fatal crashes (Fatal) decreased from four (in the before period) to one after the lay-out change. Indeed there were four accidents with at least one person killed in the period before the road works and one crash with at least one person killed in the period after. The number of slight crashes (no serious bodily injuries involved) recorded in the same period were more than halved. For the same lengths of time, on a portion of National Road 17 used as a control area, accident reports are the following.
The values given in
Parameters β 1 , β 2 and β 3 enable us to assess the risks for each type of accident on the test area in the eight years when the road markings’ effects are studied. Estimated values β ^ 1 , β ^ 2 and β ^ 3 are respectively 0.1525 , 0.1605 and 0.6870 . These values suggest that in the eight years of road marking analysis, 15.25 % of the crashes recorded in the test area were fatal, 16.05 % were serious and 68.70 % were slight as compared to the crashes recorded in the control area.
The estimated mean efficiency index ( θ ^ ) is 0.7054. It corresponds to an average decrease in proportion of 29.46 % = ( 1 − 0.7054 ) × 100 % of the whole
Accident data before | Accident data after | Total | ||||
---|---|---|---|---|---|---|
Fatal | Serious | Slight | Fatal | Serious | Slight | |
4 | 4 | 16 | 1 | 1 | 7 | 33 |
Fatal | Serious | Slight |
---|---|---|
0.519 | 0.422 | 0.560 |
Parameters | Estimations | Standard error | ||
---|---|---|---|---|
Lower bound | Upper bound | |||
0.7054 | 0.2760 | 0.1645 | 1.2463 | |
0.1525 | 0.0626 | 0.0298 | 0.2752 | |
0.1605 | 0.0639 | 0.0353 | 0.2858 | |
0.6870 | 0.0807 | 0.5287 | 0.8452 |
set of accidents in the test area as compared to the average trend in the control area. The mean effect significance for this type of lay-out may also be tested by using the confidence interval at the 95 % level associated to parameter θ . This confidence interval reveals a bracket of values whose lower (resp. upper) bound is strictly superior to 0 (resp. 1). Indeed, as 1 ∈ [ 0.1646 , 1.2463 ] , we cannot rule out the hypothesis H 0 : θ = 1 versus H 1 : θ ≠ 1 with a type-1 error of 5 % . Even if in the case studied here, we can notice a decrease in proportion of 29.46 % = ( 1 − 0.7054 ) × 100 % in the average accident number in the test area, the above test shows that the mean efficiency index value is not significantly different from 1 to enable us to conclude that this type of road marking is efficient. In practice, an analysis according to periods, recorded data and control area should be carried out in order to get more appropriate conclusions.
We propose in this paper, under assumptions, a principle of 2-block splitting of a constrained Maximum Likelihood (ML) system of equations linked to a parameter vector. We obtain analytical approximations of the components of the constrained ML estimator. The standard asymptotic errors are also obtained in closed-form.
We then build an iterative algorithm by initializing the first component of the parameter vector without inverting (at each iteration) the information matrix nor the Hessian matrix. Our partial linear approximation algorithm cycles through the components of the parameter vector and updates one component at a time. It is very simple to program and the constraints are integrated easily. To implement our algorithm, we use a particular version of the multinomial model of N’Guessan et al. [
The numerical performance of the proposed algorithm is examined through a simulation study and compared to those of classical methods available in R and MATLAB software. The choice of these other methods is dictated not only by the fact that they are relevant and integrated in most statistical software but also by the fact that some need second order derivatives and others do not. The comparisons suggest that not only the partial linear approximation algorithm is competitive in statistical accuracy and computational speed with the best currently available algorithm, but also it is not disturbed by the initial guess.
The link between the numerical performance of our algorithm and the particular model used in this paper seems to be a limitation to the com- petitiveness of our algorithm with regards to the other methods considered in this paper. However, this particular choice of model allows not only to show the feasibility of our algorithm but also represents a good basis for approaching, under additional conditions, more general models.
The simulations results obtained on the particular model considered in this paper suggest that our algorithm may be extended to other families of multi- nomial models (such as the model of N’Guessan et al. [
We thank the Editor and the anonymous referee for their remarks and suggestions which enabled a substantial improvement of this paper. This article was partially written while the second author was visiting the Lille 1 University (France).
N’Guessan, A., Geraldo, I.C. and Hafidi, B. (2017) An Approximation Method for a Maximum Likelihood Equation System and Application to the Analysis of Accidents Data. Open Journal of Statistics, 7, 132-152. http://dx.doi.org/10.4236/ojs.2017.71011
Proof. Problem (3) is equivalent to maximizing function
L ( ϕ , λ ) = l ( ϕ ) − λ C ( ϕ ) (21)
where λ is the Lagrange multiplier. Any solution ϕ ^ must satisfy
( ∂ L ∂ θ ) ϕ ^ = 0 and ( ∂ L ∂ β j ) ϕ ^ = 0 , j = 1 , ⋯ , r . (22)
From assumption 3, system (22) is equivalent to
( ∂ l ∂ θ ) ϕ ^ = 0 and ( ∂ l ∂ β j ) ϕ ^ − λ ^ ( ∂ C ∂ β j ) ϕ ^ = 0 , j = 1 , ⋯ , r (23)
where λ ^ = λ ( ϕ ^ ) . After multiplication by β ^ j and summation on the index j , we get:
∑ j = 1 r β ^ j ( ∂ l ∂ β j ) ϕ ^ − λ ^ ∑ j = 1 r β ^ j ( ∂ C ∂ β j ) ϕ ^ = 0.
that is equivalent to
〈 β ^ , ( ∂ l ∂ β ) ϕ ^ 〉 − λ ^ 〈 β ^ , C β ^ 〉 = 0.
We obtain (6) by substitution of λ ^ in (23). □
Proof. Under conditions 6, Γ ϕ is non singular and after some matrix mani- pulations, we get
Γ ϕ − 1 = [ W ϕ J ϕ − 1 C ϕ T R ϕ − 1 R ϕ − 1 C ϕ J ϕ − 1 − R ϕ − 1 ] , J ϕ − 1 = [ ( J ϕ / B ϕ ) − 1 − ( J ϕ / B ϕ ) − 1 U ϕ T B ϕ − 1 − B ϕ − 1 U ϕ ( J ϕ / B ϕ ) − 1 ( J ϕ / τ ϕ ) − 1 ]
where R ϕ − 1 = a n , ϕ ‖ C β ‖ Σ ϕ − 1 − 2 is a scalar, B ϕ − 1 = a n , ϕ − 1 ( Σ ϕ − 1 − ( 1 + ‖ V ϕ ‖ Σ ϕ − 1 2 ) − 1 Σ ϕ − 1 V ϕ V ϕ T Σ ϕ − 1 )
is the inverse of B ϕ , ( J ϕ / B ϕ ) − 1 = b n , ϕ − 2 a n , ϕ ( 1 + ‖ V ϕ ‖ Σ ϕ − 1 2 ) , is a scalar,
( J ϕ / τ ϕ ) − 1 = a n , ϕ − 1 Σ ϕ − 1 , is a r × r matrix and W ϕ = J ϕ − 1 − J ϕ − 1 C ϕ T R ϕ − 1 C ϕ J ϕ − 1 is the ( 1 + r ) × ( 1 + r ) asymptotic variance-covariance matrix of ϕ . We show that
W ϕ = [ W ϕ ( 1 , 1 ) W ϕ T ( 2 , 1 ) W ϕ ( 2 , 1 ) W ϕ ( 2 , 2 ) ]
where W ϕ ( 1 , 1 ) is a scalar and W ϕ ( 2 , 2 ) is a r × r matrix. The asymptotic variance of θ ^ is given by W ϕ ( 1 , 1 ) and σ ^ 2 ( β ^ j ) is obtained by the diagonal elements of W ϕ ( 2 , 2 ) . After straightforward calculation, we get
W ϕ ( 1 , 1 ) = ( J ϕ / B ϕ ) − 1 − R ϕ − 1 ξ ϕ 2 ( J ϕ / B ϕ ) − 2 b n , ϕ 2 a n , ϕ − 2 ( 1 + ‖ V ϕ ‖ Σ ϕ − 1 2 ) 2
and
W ϕ ( 2 , 2 ) = a n , ϕ − 1 ( Σ ϕ − 1 − ‖ C β ‖ Σ ϕ − 1 − 2 Σ ϕ − 1 C β C β T Σ ϕ − 1 )
where ξ ϕ = V ϕ T Σ ϕ − 1 C β . The results of Theorem 2 follow from a direct calculation.
□
Proof. Taking the second derivatives of the negative of L with respect to the
components of ϕ and λ , we show that: ∂ 2 L ∂ λ 2 = ∂ 2 L ∂ λ ∂ θ = 0 , ∂ 2 L ∂ λ ∂ β j = − 1 , ∂ 2 L ∂ θ 2 = − y 2. θ 2 + n ( E ( Z ) ) 2 ( 1 + θ E ( Z ) ) 2 , ∂ 2 L ∂ θ ∂ β j = − n z j ( 1 + θ E ( Z ) ) 2 and
∂ 2 L ∂ β j ∂ β k = { − y . j β j 2 + n θ 2 z j 2 ( 1 + θ E ( Z ) ) 2 − y 2. z j 2 ( E ( Z ) ) 2 if j = k n θ 2 z j z k ( 1 + θ E ( Z ) ) 2 − y 2. z j z k ( E ( Z ) ) 2 if j ≠ k
for j , k = 1 , ⋯ , r . Now, setting E ( y . j ) = n β j , E ( y 2. ) = n θ E ( Z ) / ( 1 + θ E ( Z ) ) and γ = n / ( 1 + θ E ( Z ) ) , we obtain the components of matrix J ϕ as follows
τ ϕ = γ 2 E ( Z ) n θ , U ϕ , j = γ 2 z j n , B ϕ , j j = γ ( n γ β j + γ θ 2 z j 2 n E ( Z ) ) and B ϕ , j k = θ γ 2 z j z k n E ( Z ) , ( j ≠ k )
where U ϕ , j (resp. B ϕ , j j and B ϕ , j k ) are the components of vector U ϕ (resp. the elements of matrix B ϕ ). Using the last expressions of the elements of U ϕ and B ϕ and after straightforward calculation, we show that
W ϕ ( 2 , 2 ) = γ − 1 Σ ϕ − 1 − 1 n β β T and then, we deduce the expression of σ ^ 2 ( β ^ j )
given by corollary 2. In the same way, we obtain
W ϕ ( 1 , 1 ) = n θ γ 2 t ϕ E ( Z ) − θ 2 n
where t ϕ = [ n 2 E ( Z ) ] / [ n 2 E ( Z ) + θ γ 2 E ^ ( Z 2 ) ] . Using the last expression of t ϕ , we get the expression of σ ^ 2 ( θ ^ ) . □