# plot.smplx: Draws a two dimentional plot of the vertexes in a simplex In labsimplex: Simplex Optimization Algorithms for Laboratory and Manufacturing Processes

## Description

The function generates a 2D plot of the vertexes in a simplex optimization when simplex dimensionality is at least 2. When dimensionality is higher than 2, the plot produced is a projection of the selected variables.

## Usage

 ```1 2 3``` ```## S3 method for class 'smplx' plot(x, sel.dim = NULL, all.ver = TRUE, all.lin = TRUE, expand = TRUE, exp.fac = 1.5, ...) ```

## Arguments

 `x` object of class `smplx`. `sel.dim` `numeric` or `char` vector for variables to be considered when simplex dimensionality is higher than 2. By default, the first two are chosen. If the vector is `numeric`, it must contain the ordinal numbers corresponding to the desired variables. If the vector is of class `char`, it must contain the names of such dimensions. `all.ver` logical default to `TRUE`. Should all vertexes be plotted? If `FALSE`, the function draws only the vertexes of the current simplex. `all.lin` logical default to `TRUE`. Should all lines be drawn? If `FALSE`, the function draws only the lines of the last simplex. `expand` logical default to `TRUE`. Should the plot scales be expanded? `exp.fac` expansion factor used when `expand = TRUE`. `...` other graphical parameters used in `plot`

## Details

For 3D representations of simplexes with dimensionality higher than 2 you can use `plotSimplex3D`.

## Value

2D plot of the simplex coordinates.

## Author(s)

Cristhian Paredes, craparedesca@unal.edu.co

Jesús Ágreda, jagreda@unal.edu.co

`plotSimplex3D`
 ``` 1 2 3 4 5 6 7 8 9 10 11 12``` ``` plot(x = labsimplex(n = 2, centroid = c(7, 340), stepsize = c(1.2, 15))) ## Several options are posible when visualizing higher order simplexes plot(x = labsimplex(n = 3)) plot(x = labsimplex(n = 3), sel.dim = c(2, 3)) ## Simplex movements can be visualized after some experiments has been ## performed simplex <- exampleOptimization(surface = exampleSurfaceR2, centroid = c(7, 340), stepsize = c(1.2, 15), experiments = 16) plot(x = simplex) ```