[R] create space for a matrix
Giovanni Azua Garcia
bravegag at gmail.com
Mon Mar 29 08:41:15 CEST 2010
see the matrix function e.g.
m <- matrix(0, nrow=1, ncol=3)
then you can use functions like rbind or cbind to create bigger ones.
I am a newbie so double check everything :)
On Mar 29, 2010, at 8:37 AM, leobon wrote:
> Hello all,
> I want to creat a space for a matrix.
> For example, I have a matrix with the dimension of 1(row)*3(col), which is
> (2,3,4). Then I want to put this matrix into a new and larger matrix. The
> dimension of the new matrix is 3*3. So what I want is creating a new larger
> matrix which allows me to put each smaller matrix with the same columns into
> I know 0*(1:3) is the way to creat a space for 3 numbers. Could any body
> tell me how to creat a space for a matrix?
> Appreciate very much for your help!
> View this message in context: http://n4.nabble.com/create-space-for-a-matrix-tp1694754p1694754.html
> Sent from the R help mailing list archive at Nabble.com.
> R-help at r-project.org mailing list
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
More information about the R-help