50% off | Unlimited Data & AI Learning
Get 50% off unlimited learning

sitools (version 1.4)

kilo: SI prefixes

Description

SI prefixes are defined as constant factors like kilo <- 1000

Arguments

Details

SI prefixes are defined as constant factors like kilo <- 1000 The use of constants for SI prefixes will make your code readable. It reduces the risk of mistakes and supports the usage of SI units. The BIPM provides a list of prefixes. All of them are available as constants in sitools.

References

http://www.bipm.org/en/si/si_brochure/chapter3/prefixes.html

Examples

Run this code
library(sitools)

# dice have a volume of (in metres)
a <- 1 * centi
volumedice <- a^3
volumedice

# how many dice fit in a box with
# 10 cm height
# 20 cm length 
# 30 cm width

volumebox <- 10*centi * 20*centi * 30*centi

volumebox / volumedice

Run the code above in your browser using DataLab