It could be useful to have an argument of numbers of digits in the function makeup_num that if it is not NULL overrides the numbers of digits of the sample argument.
I say this because when used programmatically; or at least in the bar-chart-race app example:
there is a selector for the format of numbers (1.234,5; 1,234.5; 1 234.5; ...) and a numeric input for the number of digits after the decimal mark
how can they be integrated in an easy way?