On Wed, 30 Dec 2020 at 02:22, [email protected] <[email protected]> wrote:
>> * Martin Michlmayr <[email protected]> [2020-12-24 13:43]: >> > = /^Pizza:/ >> > Pizza:Taxes (roundto(amount * 0.0775, 2)) >> > CreditCard (roundto(-amount * 0.0775, 2)) > The problem is the ceil() function that roundto() in turn uses. That is a > positive biased rounding function, which rounds up towards +∞, instead of > rounding away from/toward zero. Then maybe round first, negate second? = /^Pizza:/ Pizza:Taxes (roundto(amount * 0.0775, 2)) CreditCard (-roundto(amount * 0.0775, 2)) -- --- You received this message because you are subscribed to the Google Groups "Ledger" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/ledger-cli/CAP_d_8WtqKb5zyQmgnV%3DEKADEtF8LB47PJ-yuYUZqMJ5wT-Nxw%40mail.gmail.com.
