Dear r-help, Could you help me to find the function which create an empty matrix. I use matrix(), but it gives *a single value that is NA and length of this matrix is 1.* ** *Best Regards* [[alternative HTML version deleted]]
On 10/05/2010 7:15 AM, anderson nuel wrote:> Dear r-help, > > Could you help me to find the function which create an empty matrix. > > I use matrix(), but it gives *a single value that is NA and length of this > matrix is 1.*Not sure what you mean by an empty matrix, but here's one interpretation: matrix(numeric(0), 0,0) This gives a 0 by 0 matrix. Duncan Murdoch
On 10.05.2010 13:15, anderson nuel wrote:> Dear r-help, > > Could you help me to find the function which create an empty matrix.Help is: ?matrix Uwe Ligges> > I use matrix(), but it gives *a single value that is NA and length of this > matrix is 1.* > ** > *Best Regards* > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code.
I think matrix(nrow=0, ncol=0) will do it. -Ista On Mon, May 10, 2010 at 7:15 AM, anderson nuel <anderson.nue@gmail.com>wrote:> Dear r-help, > > Could you help me to find the function which create an empty matrix. > > I use matrix(), but it gives *a single value that is NA and length of > this > matrix is 1.* > ** > *Best Regards* > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. >-- Ista Zahn Graduate student University of Rochester Department of Clinical and Social Psychology http://yourpsyche.org [[alternative HTML version deleted]]