fixed.intervals {wbs} | R Documentation |
The function generates approximately M
intervals with endpoints in 1
,2
,...,n
, without random drawing. This routine
can be used inside wbs
function and is typically not called directly by the user.
fixed.intervals(n, M)
n |
a number of endpoints to choose from |
M |
a number of intervals to generate |
Function finds the minimal m
such that \code{M} <= \code{m(m-1)/2}.
Then it generates m
approximately equally-spaced positive integers lower than n
and returns all possible intervals consisting of any two of these points.
a 2-column matrix with start (first column) and end (second column) points of an interval in each row
fixed.intervals(10,100)