| format {ctmm} | R Documentation | 
Scientific formatting of numbers
Description
Functions for concisely representing dimensionful quantities and uncertain quantities.
Usage
dimfig(data,dimension,thresh=1,...)
sigfig(est,VAR=NULL,SD=NULL,level=0.95,digits=2,...)
Arguments
data | 
 A numerical vector of dimensionful quantities represented in SI units.  | 
dimension | 
 One of   | 
thresh | 
 Threshold quantity for switching between units. E.g., 100 cm is represented as 1 m only if   | 
est | 
 Can be either confidence-interval estimates with rows (lower-limit,point-estimate,upper-limit) or point estimates (with   | 
VAR | 
 Variance in the sampling distribution of   | 
SD | 
 Standard deviation in the sampling distribution of   | 
level | 
 Confidence level for designating the numerical precision of the significant digits.  | 
digits | 
 Number of significant digits to retain.  | 
... | 
 Not currently used.  | 
Details
dimfig chooses the set of units that provides the most concise representation for data, and sigfig concisely represents statistical estimates with a fixed number of significant digits.
Value
dimfig returns a list with slots for the converted data and the name of the most concise units. sigfig returns a character string that is formated with the specified number of significant digits.
Author(s)
C. H. Fleming.
See Also
Examples
# Load package and data
library(ctmm)
data(buffalo)
DATA <- buffalo$Cilla
GUESS <- ctmm.guess(DATA,interactive=FALSE)
# in general, you want to run ctmm.select instead
FIT <- ctmm.fit(DATA,GUESS)
# raw summary (SI units)
summary(FIT,units=FALSE)
# default summary (concise units)
summary(FIT,units=TRUE)
# text-formatted summary
sigfig( summary(FIT)$CI )