powered by
Computes the number of the significant digits based on the smallest non-zero difference of the sorted data.
mmstat.dec(x, ord = NULL)
The number of significant digits and (the subset of) the order of the data.
numeric: data vector
index: subset of the ordered data (default: NULL)
NULL
x <- rnorm(20) d <- mmstat.dec(x) # create strings so that they are unique (if they were) sprintf("%.*f", d$dec, x)
Run the code above in your browser using DataLab