Results for “money”
100 capabilities
money.split-even
Split an amount into n near-equal parts that add back up to exactly the whole.
split_even in Rust
money.convert
Convert an amount to another currency at a supplied exact rate, with an explicit rounding mode.
convert_money in Rust
money.compare → compareMoney
Compare two amounts of one currency, refusing to compare across currencies; min, max and clamp too.
compare_money in Rust, one function of this group
money.format
Render a monetary amount as text, using the currency's real minor-unit precision.
format_money in Rust
money.parse
Parse "£1,234.50" or "1.234,50 €" into integer minor units, strictly: no guessing, no rounding.
parse_money in Rust
money.sum
Total a list of monetary amounts, with an explicit currency for the empty case.
sum_money in Rust
money.allocate
Split an amount across ratios without losing or inventing a single minor unit.
allocate in Rust
money.apply-rate
Apply a rate expressed in basis points to a monetary amount, with an explicit rounding mode.
apply_rate in Rust
invest.money-weighted-return Unreviewed
Money-weighted return (XIRR) of dated cash flows on Excel's actual/365 convention, solved exactly in fixed point.
money_weighted_return in Rust
charts.format → formatMoneyTick
Axis and label text for charts: tick numbers, SI prefixes (1.2k, 3.4M), percentages, dates and money.
format_money_tick in Rust, one function of this group
money.currency-digits
How many decimal places a currency's minor unit has, from the ISO 4217 list.
currency_digits in Rust
legal.court-fee Unreviewed
The court fee to issue a money claim in England and Wales, from the claim value bands in force on a date.
court_fee in Rust
legal.retainer-drawdown Unreviewed
Apply money held on account in client account to bills in order: what each bill takes, what stays due, what is left.
retainer_drawdown in Rust
math.round-div-big
Divide two integers of any size with an explicit rounding mode, on decimal strings, for exact money sums past 2^53.
round_div_big in Rust
invest.pension-annual-allowance Unreviewed
UK pension annual allowance for a tax year with taper, MPAA and three-year carry-forward, and the excess charged.
pension_annual_allowance in Rust
math.round-div
Integer division with an explicit rounding mode, for money arithmetic that must not drift.
round_div in Rust
text.number-to-words
Write a money amount in words for a cheque: "one thousand two hundred and thirty-four pounds and fifty-six pence".
amount_in_words in Rust
agri.feed-ration
Ration costing and dry matter intake from each feed's fresh weight, DM % and price per tonne, in exact money.
feed_ration in Rust
agri.gross-margin
Enterprise gross margin (output less variable costs), in total and per hectare or per head, in exact money.
gross_margin in Rust
inventory.valuation-fifo
FIFO stock valuation and cost of sales from a stock movement ledger, in exact money.
fifo_valuation in Rust
banking.cheque-amount-words
The words and figures to write on a cheque: "One hundred and twenty pounds and fifty pence only", "£120.50".
cheque_amount_words in Rust
payroll.overtime Unreviewed
Pay for the time worked in a period split into multiplier bands: basic, time and a half after 40 hours, double time.
overtime_pay in Rust
finance.early-payment-discount
Early settlement discount available on a payment date under "2/10 net 30" style terms, and the amount to pay.
early_payment_discount in Rust
finance.proration
Split an amount into the part used and the part unused over a billing period, losing nothing.
prorate in Rust
banking.faster-payments-limit
Whether a Faster Payment fits the scheme maximum, the bank's per-payment limit and what is left of its daily limit.
faster_payments_check in Rust
education.fee-instalments
Tuition fee instalment schedule from a total, shares and due dates, exact to the penny.
fee_instalments in Rust
charity.donation-matching
Employer match on a donation: a ratio in basis points, limited by a per-donor cap and a programme budget.
donation_match in Rust
fleet.mileage-allowance
HMRC approved mileage allowance payments for an employee's own vehicle: tax-free amount, taxable excess or relief.
mileage_allowance in Rust
hospitality.tronc-allocation
Share a tips pool (tronc) between staff by hours worked, points, or hours times points, exactly to the penny.
tronc_allocation in Rust
payroll.student-loan Unreviewed
Student loan or postgraduate loan deduction from one period's pay, by plan, rounded down to whole pounds.
student_loan in Rust
finance.compound-interest
Compound interest accrued period by period in minor units, the way a statement is built.
compound_interest in Rust
text.integer-to-words
Spell out a whole number in British English words, with "and" the way a cheque writes it.
integer_to_words in Rust
charity.payroll-giving
UK Payroll Giving for one pay period: the donation comes off pay before PAYE, and the tax it saves the employee.
payroll_giving in Rust
payroll.pension-auto-enrolment Unreviewed
Workplace pension contributions for one pay period: qualifying earnings band, employee and employer shares, tax relief.
pension_contributions in Rust
lending.affordability Unreviewed
Debt-to-income and a stressed-rate affordability test for a proposed loan's monthly repayment.
affordability in Rust
finance.margin
Profit on a sale with both the margin and the markup, so the two are never confused.
margin in Rust
invest.fee-drag Unreviewed
What an annual charge costs an investment over the years: value with and without the fee, year by year, in minor units.
fee_drag in Rust
invest.dividend-yield Unreviewed
Trailing and forward dividend yield of a share or fund, in basis points, from the price and the dividends per unit.
dividend_yield in Rust
property.mortgage-affordability Unreviewed
Mortgage affordability: the loan-to-income multiple and a stress-tested repayment against income, both checked.
mortgage_affordability in Rust
property.deposit-cap Unreviewed
Maximum tenancy deposit a landlord may take: five or six weeks' rent under the Tenant Fees Act 2019.
deposit_cap in Rust
legal.statutory-interest Unreviewed
Statutory interest on a judgment debt (8% simple, daily) or a late commercial debt, England and Wales.
statutory_interest in Rust
charity.gift-aid-eligibility
Whether a UK donation qualifies for Gift Aid: declaration, enough tax paid, and the donor benefit limits.
gift_aid_eligibility in Rust
retail.oss-vat
EU distance-selling VAT: which member state's standard rate applies under OSS and the EUR 10,000 threshold, and the VAT.
oss_vat in Rust
hospitality.bill-split
Split a restaurant bill evenly, by item or by share, exactly to the penny, with the service charge shared in proportion.
bill_split in Rust
charity.restricted-funds
Allocate charity spending to restricted funds first, then unrestricted funds, never overdrawing a restricted fund.
allocate_fund_spend in Rust
finance.depreciation-straight-line
Straight-line depreciation schedule whose charges sum exactly to cost less residual value.
straight_line_depreciation in Rust
manufacturing.batch-size
Economic batch quantity: the EOQ for a batch made at a finite production rate, in whole units.
economic_batch_quantity in Rust
retail.basket-total
Total a basket: line prices, promotions, a basket discount, VAT per line and delivery, into one checked total.
basket_total in Rust
finance.accruals-prepayments
Split an invoice across accounting periods by days of service, for accruals, prepayments and deferred income.
allocate_to_periods in Rust
finance.depreciation-reducing-balance
Reducing-balance depreciation schedule at a fixed rate, writing off to the residual value in the final year.
reducing_balance_depreciation in Rust
inventory.eoq
Economic order quantity (Harris/Wilson): the order size that minimises ordering plus holding cost, in whole units.
economic_order_quantity in Rust
retail.gift-card-balance
Apply a payment from a gift card, redeeming part of the balance or all of it, and say what is still due.
redeem_gift_card in Rust
retail.price-rounding
Snap a price to a price point: charm pricing (.99, .95), nearest 5p or 10p, rounding up, down or to nearest.
round_price in Rust
charity.fundraising-ratio
Cost to raise £1 and charitable spend ratio for a charity, in exact basis points.
fundraising_ratios in Rust
construction.day-rate-quote
A trade quote from labour days at a day rate, materials with a markup, and VAT.
day_rate_quote in Rust
retail.refund-calculate
Refund for returned items, sharing basket discounts back across the sale so every refund is exact to the penny.
calculate_refund in Rust
retail.loyalty-points
Loyalty points for a purchase: redeem in blocks, earn on what is paid, with tier multipliers.
loyalty_points in Rust
charity.gasds
Gift Aid Small Donations Scheme top-up for a tax year: the £8,000 limit, the matching rule and community buildings.
gasds in Rust
finance.markup-price
Selling price from a cost and a target margin or markup in basis points, with explicit rounding.
markup_price in Rust
telecoms.data-allowance
Mobile data allowance used and remaining, and the overage charge in whole blocks with an optional spend cap.
data_allowance in Rust
insurance.ipt Unreviewed
UK Insurance Premium Tax at the standard or higher rate in force on a date, added to or taken out of a premium.
insurance_premium_tax in Rust
finance.tax.remove-vat Unreviewed
Extract the VAT already included in a gross amount, using the rate in force on the date of supply.
remove_vat in Rust
payroll.national-insurance Unreviewed
Employee and employer Class 1 National Insurance for one payment by category letter, exact percentage method.
national_insurance in Rust
finance.tax.add-vat Unreviewed
Add VAT to a net amount using the rate in force on the date of supply.
add_vat in Rust
insurance.sum-insured-average Unreviewed
Average clause settlement for underinsurance: the loss times sum insured over value at risk, capped at the loss.
average_clause_settlement in Rust
lending.overpayment-effect Unreviewed
What a one-off overpayment does to a loan: a shorter term at the same payment, or a lower payment over the same term.
overpayment_effect in Rust
payroll.income-tax Unreviewed
PAYE income tax for one pay period from a tax code, cumulative or week 1/month 1, by HMRC's tax table routines.
income_tax in Rust
insurance.premium-proration Unreviewed
Return premium on mid-term cancellation, pro rata or on a short-period scale, with an optional minimum retained premium.
cancellation_return_premium in Rust
insurance.rating-factors Unreviewed
Premium from a base rate times factor-table lookups, loadings and discounts, within minimum and maximum premiums.
rate_premium in Rust
invest.cagr Unreviewed
Compound annual growth rate between two values over a whole or fractional number of years, in basis points.
cagr in Rust
invest.drawdown-sustainability Unreviewed
How many years a pension or investment pot lasts under a yearly withdrawal and a constant growth rate, year by year.
drawdown_sustainability in Rust
payroll.minimum-wage-check Unreviewed
Check pay for a pay reference period against the minimum or living wage for age and apprenticeship.
minimum_wage_check in Rust
property.completion-statement Unreviewed
A buyer's completion statement: price less deposit, ground rent and service charge apportioned to completion, plus fees.
completion_statement in Rust
finance.tax.vat-flat-rate Unreviewed
UK VAT Flat Rate Scheme: VAT due on gross turnover at the sector's dated rate, limited cost rate and first-year 1% off.
flat_rate_vat in Rust
insurance.excess-apply Unreviewed
Claim payout after the compulsory and voluntary excess, capped at the policy limit.
apply_excess in Rust
payroll.net-to-gross Unreviewed
The gross pay that gives at least a target net pay in one UK pay period, found by a deterministic search.
net_to_gross in Rust
insurance.claim-reserve Unreviewed
Claim reserve history: paid, recovered, outstanding and incurred after each transaction, and the movement.
claim_reserve_history in Rust
insurance.loss-ratio Unreviewed
Loss ratio, expense ratio and combined ratio in basis points, from earned premium, incurred claims and expenses.
loss_ratios in Rust
lending.loan-payment Unreviewed
Level repayment for a loan (annuity formula), computed exactly and rounded once, the way you choose.
loan_payment in Rust
payroll.statutory-maternity-pay Unreviewed
UK Statutory Maternity Pay: LEL eligibility and 39 weekly amounts, 90% then the lower of 90% or the flat rate.
statutory_maternity_pay in Rust
payroll.statutory-sick-pay Unreviewed
UK Statutory Sick Pay for sickness spells: waiting days, 8-week linking, 28-week limit and the rate by date.
statutory_sick_pay in Rust
property.rent-proration Unreviewed
Rent for part of a month from the monthly rent, by the annual-daily or the calendar-month method.
prorate_rent in Rust
property.service-charge-apportion Unreviewed
Apportion a service charge across units by lease fraction, floor area or fixed percentage, exact to the penny.
apportion_service_charge in Rust
retail.sales-tax-us Unreviewed
US sales tax on a sale: the state's base rate from dated data plus a local rate the caller supplies.
sales_tax_us in Rust
insurance.mid-term-adjustment Unreviewed
Additional or return premium for a mid-term policy change, pro rata on the days left, plus an admin fee.
mid_term_adjustment in Rust
invest.capital-gains-tax Unreviewed
UK Capital Gains Tax for an individual's tax year: losses, annual exempt amount, and the rates by asset and date.
capital_gains_tax in Rust
invest.portfolio-weights Unreviewed
Each holding's share of a portfolio and its drift from a target weight, in basis points, from exact arithmetic.
portfolio_weights in Rust
invest.rebalance Unreviewed
Whole-unit buy and sell trades that bring a portfolio back to target weights, skipping trades below a minimum size.
rebalance in Rust
invest.time-weighted-return Unreviewed
Time-weighted return from valuations taken at each external cash flow, geometrically linked exactly.
time_weighted_return in Rust
lending.amortisation-schedule Unreviewed
Repayment schedule for a level-payment loan: interest, principal and balance per period, ending at exactly zero.
amortisation_schedule in Rust
property.council-tax-band Unreviewed
Council tax for a valuation band from the Band D charge: the statutory band ratio, England, Wales and Scotland.
council_tax_band in Rust
property.holding-deposit-cap Unreviewed
Maximum holding deposit to reserve a rental property: one week's rent (annual rent ÷ 52), rounded down.
holding_deposit_cap in Rust
property.rental-yield Unreviewed
Gross and net rental yield of a let property, in basis points, from annual rent, costs and value.
rental_yield in Rust
insurance.instalment-plan Unreviewed
Pay a premium by monthly instalments: deposit, flat credit charge, instalments exact to the penny, and the APR.
instalment_plan in Rust
logistics.duty-estimate Unreviewed
Estimate import duty and import VAT on goods: customs value on a CIF basis, the caller's duty rate, VAT on top.
duty_estimate in Rust
payroll.pro-rata-salary Unreviewed
Salary for part of a pay period and for part-time hours, by calendar days or working days, rounded once.
pro_rata_salary in Rust
lending.ltv Unreviewed
Loan-to-value ratio in basis points, and the band it falls in from a band table you supply.
loan_to_value in Rust
payroll.holiday-pay-accrual Unreviewed
UK holiday pay: 12.07% rolled-up holiday pay, or a week's pay averaged over the last 52 paid weeks.
holiday_pay in Rust