Starr Global Optimality Test {accuracy}R Documentation

Function to test that an optimum from MLE, NLS, or other non-linear optization routine is a global optimum

Description

Implements the Starr test for identification of the global optimum of a likelihood surface.

Usage

 starr(betas, tol=.0001, dmethod="euclidean")

Arguments

betas Vector of parameter values
tol Tolerance distance between two parameter vectors to consider as "unique" optimum
dmethod method used to compute distance between two parameter vectors

Details

texttt{starr} computes the probability that a local optimum, which may or may not be the global optimum, of a likelihood function has not been observed. The probability is generated by counting the observed number of ``basins of attraction'' - starting values that lead to an local optimum.

Value

texttt{starr} is a class "double" with value equal to the probability than a local optimum is unobserved.

Note

texttt{starr} is given a vector of texttt{betas} parameter values identifying local optima resultant of a search algorithm, such as texttt{mle} or texttt{nls}. The starting values used to generate texttt{betas} can be a grid, or for larger n-dimenional parameter spaces, may be randomly chosen. The parameter values identifying a local optimum are passed to texttt{starr} for each set of starting values that lead to that local optimum.

Author(s)

Micah Altman Micah_Altman@harvard.edu http://www.hmdc.harvard.edu/micah_altman/ , Michael McDonald

References

Altman, M., J. Gill and M. P. McDonald. 2003. Numerical Issues in Statistical Computing for the Social Scientist. John Wiley & Sons. http://www.hmdc.harvard.edu/numerical_issues/

Finch, S. J., Mendell, N. R., Thode, H. C., Jr. 1989. ``Probabilistic Measures of Adequacy of a Numerical Search for a Global Maximum.'' Journal of the American Statistical Association {bf 84}, 1020-3.

Starr, N. 1979. ``Linear Estimation of the Probability of Discovering a New Species.'' Annals of Statistics {bf 7}, 644-52.

Examples


        x=rbind(c(1,1,1), c(1,2,1), c(1,1.1,1), c(1,2,1), c(3,4,5));
        starr(rbind(1,1,2,2));

        data("BOD",package="stats")
       stval=expand.grid(A = seq(10, 100, 10), lrc = seq(.5, .8, .1))
       llfun<-function(A,lrc)
             -sum((BOD$demand - A*(1-exp(-exp(lrc)*BOD$Time)))^2)
       lls=NULL 
       for (i in 1:nrow(stval))  {
          lls = rbind(lls, llfun(stval[i,1], stval[i,2]))
       }
       fm1 <- nls(demand ~ A*(1-exp(-exp(lrc)*Time)),  
                     data = BOD, start = c(A = 20, lrc = log(.35)))
       ss = -sum(resid(fm1)^2)
       dehaan(lls, ss)
       
       llb=NULL
       for (i in 1:nrow(stval))  {
        llb = rbind(llb,coef( 
        nls(demand ~ A*(1-exp(-exp(lrc)*Time)),  
                     data = BOD, start = c(A=stval[i,1], lrc = stval[i,2]))))
      }
       starr(llb)


[Package accuracy version 1.19 Index]