does this work?
{{ frappe.utils.fmt_money((x -y),currency=doc.currency) }}
Yes, this worked. Thanks for the help