Description
Map value x
linearly from interval [imin:imax]
to [omax:omax]
.
Usage
lin_map(x, imin, imax, omin = 0, omax = 1)
Arguments
- x
numeric()
. Value(s) to be mapped.
- imin
numeric()
. Lower bound of the input range.
- imax
numeric()
. Upper bound of the input range.
- omin
numeric()
. Lower bound of the output range.
- omax
numeric()
. Upper bound of the output range.