The function generates M intervals of the length smaller or equal than max.length, whose endpoints are
are drawn uniformly without replacements from 1,2,..., n. This routine can be
used inside not function and is typically not called directly by the user.
Usage
random.intervals(n, M, min.length = 1, max.length = n, ...)
Value
a M by 2 matrix with start (first column) and end (second column) points of an interval in each row