get_observations {CAISEr} | R Documentation |
Call algorithm routine for the solution of a problem instance
get_observations(algo, instance, n = 1)
algo |
a list object containing the definitions of the algorithm.
See |
instance |
a list object containing the definitions of the problem
instance. See |
n |
number of observations to generate. |
vector of observed performance values
Felipe Campelo (fcampelo@ufmg.br, f.campelo@aston.ac.uk)
# Make a dummy instance with a centered (zero-mean) exponential distribution:
instance <- list(FUN = "dummyinstance", distr = "rexp", rate = 5, bias = -1/5)
# Simulate a dummy algorithm that has a uniform distribution of expected
# performance values, between -25 and 50.
algorithm <- list(FUN = "dummyalgo",
distribution.fun = "runif",
distribution.pars = list(min = -25, max = 50))
x <- get_observations(algorithm, instance, n = 1000)
hist(x)