- decimal-align <k> <format> ...procedure
Specifies an alignment for the decimal place when formatting numbers, useful for outputting tables of numbers.
(define (print-angles x) (fmt-join num (list x (sin x) (cos x) (tan x)) " ")) (fmt #t (decimal-align 5 (fix 3 (fmt-join/suffix print-angles (iota 5) nl))))
would output
0.000 0.000 1.000 0.000 1.000 0.842 0.540 1.557 2.000 0.909 -0.416 -2.185 3.000 0.141 -0.990 -0.142 4.000 -0.757 -0.654 1.158