[Rd] cbind with different vector lengths

Geophagus falk.hilliges at twain-systems.com
Fri Aug 12 11:28:27 CEST 2011


Hi @ all,
I have the following question:
Is there a possibilty to cbind tree dataframes with different numbers of
rows?

Here is my example:

/> b2007
5 8 
1 1 

> b2008
3 6 8 
3 1 2 

> b2009
1 3 8 
1 2 1 

> cbind (b2007,b2008,b2009)

  b2007 b2008 b2009
3     1     3     1
6     1     1     2
8     1     2     1
Warnmeldung:
In cbind(b2007, b2008, b2009) :
  number of rows of result is not a multiple of vector length (arg 1)/

I also need the row name "5" and the "1" with NA or 0 as value in the
result.
I hope my problem was understandable.

Thanks a lot in advance!
Falk aka Geophagus


--
View this message in context: http://r.789695.n4.nabble.com/cbind-with-different-vector-lengths-tp3738320p3738320.html
Sent from the R devel mailing list archive at Nabble.com.



More information about the R-devel mailing list