[R] Combind two different vector

Georg Ruß research at georgruss.de
Sat Nov 27 18:37:56 CET 2010


On 27/11/10 16:04:35, Serdar Akin wrote:
> I'm trying two combine two vectors that have different lengths. This without
> recursive the shorter one. E.g.,
>
> a <- seq(1:3)
> b <- seq(1:6)

If that means your output should be (1 2 3 1 2 3 4 5 6) then
c <- c(a,b) should solve this. Looks like _the_ basic vector
operation.

Georg.
-- 
Research Assistant
Otto-von-Guericke-Universität Magdeburg
research at georgruss.de
http://research.georgruss.de



More information about the R-help mailing list