What is the go-to package for converting floating point numbers into currencies that can be added and subtracted and pretty printed on tables?
Found Currencies.jl, CurrencyAmounts.jl and Assets.jl but none of them seem to have what I need. I basically need to convert a vector of floating point into currencies for pretty printing:
julia> BRL.([1, 5, 10])
return "\$" * rsplit(@sprintf("%-12.2f",n))
You can use it as
julia> fp2currency(12.34) |> println
julia> fp2currency.([1, 5, 10])
You cannot add or subtract. You should only do this when you want to print it out.
If what you want is Currency then you could just use Unitful.jl
Thank you @barucden I will take a look.