Description Usage Arguments Value Author(s) See Also Examples
Functions to coerce object to numericmatrix
.
1 2 3 4 5 6 7 8 | ## S3 method for class 'numdfr'
as.nummatrix(object)
## S3 method for class 'numdfr.rep'
as.nummatrix(object)
## S3 method for class 'matrix'
as.nummatrix(object)
## S3 method for class 'data.frame'
as.nummatrix(object)
|
object |
object to coerce |
matrix
with the same dimensions as the original object,
and with factors converted to numericals. Have not always checked what
happens to characters...
Nick Sabbe
1 2 3 4 5 | iris.nd<-numdfr(iris)
iris.mat<-as.nummatrix(iris.nd)
iris.mat2<-as.nummatrix(iris)
#compare this to
iris.mat3<-as.matrix(iris) #becomes all character!
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.