Description Usage Arguments Value Author(s) Examples
Convert string-valued data frame or matrix into a numeric matrix
1 | asNumMatrix(x)
|
x |
A data.frame or matrix, most likely with string values |
A numeric matrix with the same dimension
Jitao David Zhang <jitao_david.zhang@roche.com>
1 2 3 4 5 | testDf <- data.frame(a=c("2.34", "4.55"), b=c("7.33", "9.10"))
asNumMatrix(testDf)
testMatrix <- matrix(c("2.34", "4.55", "9E-3","-2.44", "7.33", "9.10"), nrow=2)
asNumMatrix(testMatrix)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.