Is a number between a given range? (inclusive)
350707
public function range($val, $lower, $upper, $id, $name = null) {
        if ($val < $lower || $val > $upper) {
            if (is_null($name))
                $name = ucwords($id);
            $this->add($id, "$name must be between $lower and $upper.");
            return false;
        }

        return true;
    }
152051
function range(start, stop, step) {
  if (start != null && typeof start != 'number') {
    throw new Error('start must be a number or null');
  }
  if (stop != null && typeof stop != 'number') {
    throw new Error('stop must be a number or null');
  }
  if (step != null && typeof step != 'number') {
    throw new Error('step must be a number or null');
  }
  if (stop == null) {
    stop = start || 0;
    start = 0;
  }
  if (step == null) {
    step = stop > start ? 1 : -1;
  }
  var toReturn = [];
  var increasing = start < stop; //← here’s the change
  for (; increasing ? start < stop : start > stop; start += step) {
    toReturn.push(start);
  }
  return toReturn;
}
802955
def check_range(number, min_r, max_r, name=""):
    
    try:
        number = float(number)
        if number < min_r or number > max_r:
            raise FFmpegNormalizeError(
                "{} must be within [{},{}]".format(
                    name, min_r, max_r
                )
            )
        return number
        pass
    except Exception as e:
        raise e
622536
def _range10_90(x):
    '''
    

    '''

    x = np.delete(x, np.where(np.isnan(x)))
    i = np.argsort(x)
    a = int(0.1 * len(x))
    b = int(0.9 * len(x))
    return x[i][b] - x[i][a]
806247
def get_int_range(self, start, end, increment=None):
        """"""

        first, last = int(start), int(end)
        increment = int(increment) if increment is not None else 1
        max_length = max(len(start), len(end))

        # Zero doesn't make sense as an incrementer
        # but like bash, just assume one
        if increment == 0:
            increment = 1

        if start[0] == '-':
            start = start[1:]

        if end[0] == '-':
            end = end[1:]

        if (len(start) > 1 and start[0] == '0') or (len(end) > 1 and end[0] == '0'):
            padding = max_length

        else:
            padding = 0

        if first < last:
            r = range(first, last + 1, -increment if increment < 0 else increment)

        else:
            r = range(first, last - 1, increment if increment < 0 else -increment)

        return (self.format_value(value, padding) for value in r)
480525
def range(start, finish, step):
        """"""
        value = start
        while value <= finish:
            yield value
            value += step
194732
def __range(a, bins):
    ''''''
    a = numpy.asarray(a)
    a_max = a.max()
    a_min = a.min()
    s = 0.5 * (a_max - a_min) / float(bins - 1)
    return (a_min - s, a_max + s)
544522
def visit_Num(self, node):
        
        if isinstance(node.n, int):
            return self.add(node, Interval(node.n, node.n))
        return UNKNOWN_RANGE
855279
function(domain, range, value) {

            var domainSpan = domain[1] - domain[0];
            var rangeSpan = range[1] - range[0];
            return (((value - domain[0]) / domainSpan) * rangeSpan + range[0]) || 0;
        }
352235
function range(begin, end) {
  return test(function(ch) {
    return begin <= ch && ch <= end;
  }).desc(begin + "-" + end);
}
1024103
def isnumber(*args):
    
    return all(map(lambda c: isinstance(c, int) or isinstance(c, float), args))
1014097
function range(start, length) {
      var rgArr = [];
      if (isNum(start)) {
        function rangeLoop(isAdd) {
          if (length >= 0) {
            for (var i = 0; i < length; i++) rgArr.push(isAdd ? i + start : i);
          } else if (length < 0) {
            for (var i = 0; i > length; i--) rgArr.push(isAdd ? i + start : i);
          }
        };
        if (isUdf(length)) {
          length = start, start = UDF;
          rangeLoop(false);
        } else if (isNum(length)) {
          rangeLoop(true);
        }
      }
      return rgArr;
    }
25405
def _xxrange(self, start, end, step_count):
        """"""
        _step = (end - start) / float(step_count)
        return (start + (i * _step) for i in xrange(int(step_count)))
1166337
def in_range?( val )
      val = val.to_i
      (@above.nil? or val > @above) and
        (@below.nil? or val < @below) and
        (@valid_range.nil? or @valid_range.include?(val))
    end
37962
function check_value(val, min, max) {
    val = +val;
    if (typeof(val) != 'number' || val < min || val > max || Math.floor(val) !== val) {
        throw new TypeError("\"value\" argument is out of bounds");
    }
    return val;
}
1337863
function rangeFromIndexAndOffsets(i, before, after, length) {
  return {
    // Guard against the negative upper bound for lines included in the output.
    from: i - before > 0 ? i - before : 0,
    to: i + after > length ? length : i + after
  };
}
190426
public static function Range(int $num, int $from, int $to): bool
    {
        return ($num >= $from && $num <= $to) ? true : false;
    }