Package 'optim.functions'

Title: Standard Benchmark Optimization Functions
Description: A set of standard benchmark optimization functions for R and a common interface to sample them.
Authors: Thomas Torsney-Weir [aut, cre]
Maintainer: Thomas Torsney-Weir <[email protected]>
License: MIT + file LICENSE
Version: 0.1
Built: 2025-02-17 03:14:13 UTC
Source: https://github.com/cran/optim.functions

Help Index


Lookup information about a function by name

Description

Lookup information about a function by name

Usage

get_info(fun.name)

Arguments

fun.name

Function name to lookup


optim.functions: A collection of standard optimization functions along with a standard interface to call and sample those functions.

Description

optim.functions: A collection of standard optimization functions along with a standard interface to call and sample those functions.

Sampling functions

The sampling functions all need to have a standard interface. They all must take 2 parameters: n, the number of samples to generate and k, the number of dimensions to sample. They all return a matrix-like object containing n rows of k columns of samples.

The main interface to this library is through the sample.func function.


Unified function sampling interface.

Description

Provides a unified interface to sampling all functions. One just needs to specify the name of the function to sample, the number of samples, the dimensionality, and the sampling method and the library will take care of the rest.

Usage

sample.func(FUN.name, n, k, method = "lh.sample", ...)

Arguments

FUN.name

The name of the function to sample.

n

The number of sample points.

k

The number of dimensions to sample.

method

The sampling method.

...

Additional arguments passed to FUN.name.

Value

A data frame consisting of n rows with columns x1..xk and y1..yz where z is the number of outputs of the function.


The sampling functions take (n, k) where n is the number of samples and k is the number of dimensions. The sampling functions should return samples in a 0-1 hypercube. sampling.func <- function(n, k)

Description

The sampling functions take (n, k) where n is the number of samples and k is the number of dimensions. The sampling functions should return samples in a 0-1 hypercube. sampling.func <- function(n, k)

Usage

lh.sample(n, k, ...)

cartesian.sample(n, k, ...)

random.sample(n, k, ...)

hexagonal.sample(n, k, ...)

torus.sample(n, k, ...)

sobol.sample(n, k, ...)

halton.sample(n, k, ...)

Arguments

n

The number of samples.

k

The number of dimensions.

...

Additional arguments for the sampling (e.g. seed).