Learn R Programming

editrules (version 2.5-0)

createXlim: Utility function for generating sensible boundaries for variables Needed for mip error localization.

Description

This function determines the minimum and maximum value in x and applies an offset to it. In case of NA values will be treated as zero.

Usage

createXlim(x, factor = 1, offset = c(-1000, 1000),
    na.rm = FALSE, maxvalue = 1e+08, minvalue = -maxvalue,
    ...)

Arguments

x
data vector
factor
multiplicative factor for range of x
offset
offset added to range of x
na.rm
logical If set to TRUE NA's will be treated as zero's, otherwise if x contains NA's minvalue and maxvalue will be returned
minvalue
If x contains NA and na.rm is FALSE, the returned xlim will have minvalue as lower boundary
maxvalue
If x contains NA and na.rm is FALSE, the returned xlim will have maxvalue as upper boundary
...
not used

Value

  • a lower and upper boundary of x