[R] as.matrix strangeness

Ista Zahn izahn at psych.rochester.edu
Fri Apr 15 16:17:59 CEST 2011

Hi Michael,
It helps to look at the "Usage" section of the help pages. There you
will see that matrix() has an ncol argument, but as.matrix() does not.


On Fri, Apr 15, 2011 at 7:08 AM, Michael Bach <phaebz at gmail.com> wrote:
> Hi Adrian,
> thanks for the hint.  The problem was that it showed me help for matrix
> when I did ?as.matrix.  I thought it was some kind of convention that
> data type conversion functions start with "as.", so now I will take more
> care in the future.
> With matrix() it works as expected, thanks again.
> Michael
> ______________________________________________
> 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.

Ista Zahn
Graduate student
University of Rochester
Department of Clinical and Social Psychology

More information about the R-help mailing list