genranges: Determines "smooth" range of input data

Description Usage Arguments Details Value Author(s) Examples

View source: R/genranges.R

Description

Function genranges determines suitable lower and upper borders of numeric range covering all values of input vector. Both borders are chosen sutable rounded not to have a lot of decimals.

Usage

1
genranges(x, delta=0)

Arguments

x

numerical vector.

delta

a fraction of the range befor the first and after the last value.

Details

The genranges function determines two numbers for lower and upper border of a range, covering all the values of input vector. Both the numbers are chosen taking into account the magnitude and the accuracy of input values, such that the result is rounded by adding some space before the first and after the last value. A minimal size of this space could be defined by the argument delta.

Value

range

numerical vector of length 2: first element is the lower and second element the upper border of the range.

Author(s)

Jiri Kalina kalina@mail.muni.cz

Examples

1
2
## Input as a pair of vectors.
genranges(c(0.9,NA,18.335,8,NaN,-6.4))

genasis documentation built on May 1, 2019, 10:16 p.m.

Related to genranges in genasis...