randomsearch with parallelization and termination criteria
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.aspell
R
docs
man
tests
vignettes
.Rbuildignore
.gitignore
.travis.yml
DESCRIPTION
LICENSE
NAMESPACE
README.Rmd
_pkgdown.yml
appveyor.yml
randomsearch.Rproj

README.Rmd

---
output:
  md_document:
    variant: markdown_github
---
# randomsearch

[![CRAN_Status_Badge](http://www.r-pkg.org/badges/version/randomsearch)](https://cran.r-project.org/package=randomsearch)
[![Build Status](https://travis-ci.org/jakob-r/randomsearch.png?branch=master)](https://travis-ci.org/jakob-r/randomsearch)
[![Build status](https://ci.appveyor.com/api/projects/status/gvr607kqcl78qjq9/branch/master?svg=true)](https://ci.appveyor.com/project/jakob-r/randomsearch/branch/master)
[![Coverage Status](https://coveralls.io/repos/github/jakob-r/randomsearch/badge.svg?branch=master)](https://coveralls.io/github/jakob-r/randomsearch?branch=master)
[![Monthly RStudio CRAN Downloads](https://cranlogs.r-pkg.org/badges/randomsearch)](https://CRAN.R-project.org/package=randomsearch)

## Random Search for Expensive Functions

 Simple Random Search function for the [smoof](https://cran.r-project.org/package=smoof) and [ParamHelpers](https://cran.r-project.org/package=ParamHelpers) ecosystem with termination criteria and parallelization.

* [Documentation](https://jakob-r.github.io/randomsearch/)
* [Issues, Requests and Bug Tracker](https://github.com/jakob-r/randomsearch/issues)

```{r setup, include=FALSE}
set.seed(123)
knitr::opts_chunk$set(collapse = FALSE, warning = FALSE, error = FALSE)
library("randomsearch")
```

# Installation

We recommend to install the official release version:

```{r inst, eval = FALSE}
install.packages("randomsearch")
```

For experimental use you can install the latest development version:

```{r inst_dev, eval = FALSE}
devtools::install_github("jakob-r/randomsearch")
```

# Usage

```{r usage}
obj.fun = makeSingleObjectiveFunction(
  fn = function(x) x[1]^2 + sin(x[2]),
  par.set = makeNumericParamSet(len = 2, lower = -1, upper = 2),
  minimize = TRUE
)
res = randomsearch(obj.fun, max.evals = 10)
ind = getOptPathBestIndex(res)
getOptPathEl(res, ind)
as.data.frame(res)
```