signifarray | R Documentation |
Given a matrix or numeric data.frame, round each column to a specified column-specific number of significant digits.
signifarray(dat, digits = 6)
dat |
Required, matrix or numeric data.frame with the values to be rounded. |
digits |
Optional, 6 by default. Can be a vector as long as the number of columns in dat, where each elements specifies the number of significant digits to retain for numbers in the corresponding column of dat. |
Returns dat, but with numbers rounded based on digits parameter.
signif()
signifarray(matrix(rnorm(9*5), ncol=5), 1:5)
signifarray(data.frame(a=rnorm(10), b=rnorm(10), c=rnorm(10)), 1:3)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.