On Sat, 12 Dec 2009, Jorge Ivan Velez wrote:
Hi Kevin,
Here is a suggestion using mapply():
start <- c(1,10,20)
end <- c(4,15,27)
do.call(c, mapply( seq, start, end))
...which is what I would usually do.
But for heavy duty applications, the IRanges package and function may be
worth study
roject.org] On
Behalf Of Jorge Ivan Velez
Sent: Saturday, December 12, 2009 1:43 PM
To: Kevin Ummel
Cc: r-help@r-project.org
Subject: Re: [R] Create sequence given start and end vector
Hi Kevin,
Here is a suggestion using mapply():
start <- c(1,10,20)
end <- c(4,15,27)
do.call(c, mapply(
Hi Kevin,
Here is a suggestion using mapply():
start <- c(1,10,20)
end <- c(4,15,27)
do.call(c, mapply( seq, start, end))
See ?mapply and ?do.call for more information.
HTH,
Jorge
On Sat, Dec 12, 2009 at 2:27 PM, Kevin Ummel <> wrote:
> How can I create the following without the 'for' loop?
3 matches
Mail list logo