Data Mining Algorithms In R/Packages/optimsimplex/optimsimplex.utils

From Wikibooks, open books for an open world
Jump to navigation Jump to search

Description[edit | edit source]

These functions enable various calculations and checks on the current simplex: Compute the center of the current simplex.
optimsimplex.check Check the consistency of the data in the current simplex.
optimsimplex.deltafv Compute the vector of function value differences with respect to the function value at the first vertex (the lowest).
optimsimplex.deltafvmax Compute the difference of function value between the lowest and the highest vertices. It is expected that the first vertex (this$x[1,]) is associated with the smallest function value and that the last vertex (this$x[nbve,]) is associated with the highest function value.
optimsimplex.dirmat Compute the matrix of simplex direction, i.e. the matrix of differences of vertice coordinates with respect to the first vertex.
optimsimplex.fvmean Compute the mean of the function values in the current simplex.
optimsimplex.fvstdev Compute the standard deviation of the function values in the current simplex.
optimsimplex.fvvariance Compute the variance of the function values in the current simplex.
optimsimplex.size Determines the size of the simplex.
optimsimplex.sort Sort the simplex by increasing order of function value, so the smallest function is at the first vertex.
optimsimplex.xbar Compute the center of n vertices, by excluding the vertex with index iexcl. The default of iexcl is the number of vertices: in that case, if the simplex is sorted in increasing function value order, the worst vertex is excluded.

Usage[edit | edit source] = NULL)
   optimsimplex.check(this = NULL)
   optimsimplex.deltafv(this = NULL)
   optimsimplex.deltafvmax(this = NULL)
   optimsimplex.dirmat(this = NULL)
   optimsimplex.fvmean(this = NULL)
   optimsimplex.fvstdev(this = NULL)
   optimsimplex.fvvariance(this = NULL)
   optimsimplex.size(this = NULL, method = NULL)
   optimsimplex.sort(this = NULL)
   optimsimplex.xbar(this = NULL, iexcl = NULL)

Arguments[edit | edit source]

this The current simplex.
method The method to use to compute the size of the simplex. The available methods are the following:

’sigmaplus’ (this is the default) The sigmamplus size is the maximum 2-norm length of the vector from each vertex to the first vertex. It requires one loop over the vertices.
’sigmaminus’ The sigmaminus size is the minimum 2-norm length of the vector from each vertex to the first vertex. It requires one loop over the vertices.
’Nash’ The ’Nash’ size is the sum of the norm of the norm-1 length of the vector from the given vertex to the first vertex. It requires one loop over the vertices.
’diameter’ The diameter is the maximum norm-2 length of all the edges of the simplex. It requires 2 nested loops over the vertices.

iexcl The index of the vertex to exclude in center computation.

Value[edit | edit source] Return a vector of length nbve, where nbve is the number of vertices in the current simplex.
optimsimplex.check Return an error message if the dimensions of the various elements of the current simplex do not match.
optimsimplex.deltafv Return a column vector of length nbve-1.
optimsimplex.deltafvmax Return a numeric scalar.
optimsimplex.dirmat Return a n x n numeric matrix, where n is the dimension of the space of the simplex.
optimsimplex.fvmean Return a numeric scalar.
optimsimplex.fvstdev Return a numeric scalar.
optimsimplex.fvvariance Return a numeric scalar.
optimsimplex.size Return a numeric scalar.
optimsimplex.sort Return an updated simplex object.
optimsimplex.xbar Return a row vector of length n.

Authors[edit | edit source]

Author of Scilab optimsimplex module: Michael Baudin (INRIA - Digiteo)
Author of R adaptation: Sebastien Bihorel (

References[edit | edit source]

"Compact Numerical Methods For Computers - Linear Algebra and Function Minimization", J.C. Nash, 1990, Chapter 14. Direct Search Methods
"Iterative Methods for Optimization", C.T. Kelley, 1999, Chapter 6., section 6.2