Liking cljdoc? Tell your friends :D

tupelo.math

Miscellaneous functions.

Miscellaneous functions.
raw docstring

->bigdec-2clj

(->bigdec-2 val)

Inputs: [val :- (s/cond-pre s/Num s/Str)] Returns: BigDecimal

Coerces a numeric value to a BigDecimal with 2 decimal digits. Also accepts a numeric value encoded as a String.

Inputs: [val :- (s/cond-pre s/Num s/Str)]
Returns: BigDecimal

Coerces a numeric value to a BigDecimal with 2 decimal digits. Also accepts
     a numeric value encoded as a String.
sourceraw docstring

->bigdec-decimalsclj

(->bigdec-decimals val N)

Inputs: [val :- (s/cond-pre s/Num s/Str) N :- s/Int] Returns: BigDecimal

Coerces a numeric value to a BigDecimal with N decimal digits. Also accepts a numeric value encoded as a String.

Inputs: [val :- (s/cond-pre s/Num s/Str) N :- s/Int]
Returns: BigDecimal

Coerces a numeric value to a BigDecimal with N decimal digits. Also accepts
     a numeric value encoded as a String.
sourceraw docstring

factorialclj/s

(factorial n)

Inputs: [n :- s/Int] Returns: s/Int

Computes the factorial of N

Inputs: [n :- s/Int]
Returns: s/Int

Computes the factorial of N
sourceraw docstring

round-decimalsclj/s

(round-decimals val N)

Round a floating point number to N decimal places, returning a double.

(round-decimals 3.14156 2) => 3.14

Round a floating point number to N decimal places, returning a double.

(round-decimals 3.14156 2) => 3.14
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close