ParrConstraint: 2D constraint function

Description Usage Arguments Value Examples

View source: R/ParrConstraint.R

Description

Strongly multimdoal constraint function from Parr et al. (standardized version)

Usage

1

Arguments

x

a 2-dimensional vector or a two-column matrix specifying the location(s) where the function is to be evaluated.

Value

A scalar

Examples

1
2
3
4
5
6
7
n.grid <- 20
x.grid <- y.grid <- seq(0,1,length=n.grid)
design.grid <- expand.grid(x.grid, y.grid)
response.grid <- apply(design.grid, 1, ParrConstraint)
z.grid <- matrix(response.grid, n.grid, n.grid)
contour(x.grid,y.grid,z.grid,40)
title("Parr constraint function")

DiceOptim documentation built on Feb. 2, 2021, 1:06 a.m.