dsrange: Range of inputs for a model

Description Usage Arguments Details See Also Examples

Description

dsrange creates a discrete or continuous range for the model to be computed over. Points that fall outside the range will be discarded in all features.

Usage

1
2
dsrange(x, y, discretize = 0, renderCount = 101, axes = TRUE,
  frame.plot = TRUE, ...)

Arguments

x

Specifies the minimum and maximum for the x axis. If only one value is specified, it is used as the maximum, and the minimum will default to 0. If a collection of values are provided, the minimum and maximum are used as the range.

y

Specifies the minimum and maximum for the y axis. If only one value is specified, it is used as the maximum, and the minimum will default to 0. If a collection of values are provided, the minimum and maximum are used as the range.

discretize

If a value is provided, the field is discretized into an array of points. The value specifies the distance between each point. This becomes the default when displaying dsarrows or dsdots. The number of points in the field is defined by:

renderCount

The number of points that a curve will be computed at when being displayed. Default 101.

axes

If FALSE, the axes will not be drawn. Defaults to TRUE.

frame.plot

If FALSE, the frame of the plot will not be drawn. Defaults to TRUE.

ascii

...

Further fields for the dsrange object.

Details

You may either specify a numeric x and y, in which case 0 is the lower bound and that value is the upper bound; or a range of values, in which case the min and the max of the range will be used. To specify a range from min to max, use either c(min,max) or min:max.

See Also

dsmodel

dsarrows

dsdots

Examples

1
2
3
4
5
6
7
8
9
fun <- function(X,Y) {
  list(
    X/exp(Y),
    Y/exp(X)
  )
}
model <- dsmodel(fun, title = "A range with no features!")
#Since no features are added, only the area and title are displayed.
model + dsrange(3, 3, discretize = .09)

dsmodels documentation built on May 2, 2019, 8:35 a.m.