Amortisation Module
calculating the principal balance over time, taking into account the effects of charges, interest and fee
Types and nested modules
Type/Module | Description |
final statistics resulting from the calculations |
|
a schedule showing the amortisation, itemising the effects of payments and calculating balances for each item, and producing some final statistics resulting from the calculations |
|
amortisation schedule item showing apportionment of payments to principal, fee, interest and charges |
|
a container for aggregating figures separately from the main schedule |
|
the status of the balance on a given offset day |
|
final statistics resulting from the calculations |
|
results of the amortisation schedule generation |
|
a schedule showing the amortisation, itemising the effects of payments and calculating balances for each item, and producing some final statistics resulting from the calculations |
|
amortisation schedule item showing apportionment of payments to principal, fee, interest and charges |
Functions and values
Function or value |
Description
|
Full Usage:
calculateFee feeTotal appliedPaymentDay originalFinalPaymentDay
Parameters:
int64<MeasureProduct<Cent, MeasureOne>>
appliedPaymentDay : int<MeasureProduct<OffsetDay, MeasureOne>>
originalFinalPaymentDay : int<MeasureProduct<OffsetDay, MeasureOne>>
Returns: int64<MeasureProduct<Cent, MeasureOne>>
|
calculates the total fee payable up to a particular day, based on a proportion of days elapsed vs total number of days in the original schedule
|
Full Usage:
calculatePaymentDue si originalPayment rescheduledPayment extraPaymentsBalance interestPortionL minimumPayment
Parameters:
ScheduleItem
originalPayment : int64<MeasureProduct<Cent, MeasureOne>> voption
rescheduledPayment : RescheduledPayment voption
extraPaymentsBalance : int64<MeasureProduct<Cent, MeasureOne>>
interestPortionL : int64<MeasureProduct<Cent, MeasureOne>>
minimumPayment : MinimumPayment
Returns: int64<MeasureProduct<Cent, MeasureOne>>
|
determines any payment due on the day
|
Full Usage:
calculateStats items
Parameters:
Map<int<MeasureProduct<OffsetDay, MeasureOne>>, ScheduleItem>
Returns: Schedule
|
wraps the amortisation schedule in some statistics, and optionally calculates the final APR (optional because it can be processor-intensive)
|
Full Usage:
calculateStatutoryFeeRebate sp appliedPayments initialStats appliedPaymentDay window
Parameters:
Parameters
appliedPayments : Map<int<MeasureProduct<OffsetDay, MeasureOne>>, AppliedPayment>
initialStats : InitialStats
appliedPaymentDay : int<MeasureProduct<OffsetDay, MeasureOne>>
window : int
Returns: int64<MeasureProduct<Cent, MeasureOne>>
|
for UK FCA-regulated agreements, calculates the fee rebate due
|
Full Usage:
feePercentage principal feeTotal
Parameters:
int64<MeasureProduct<Cent, MeasureOne>>
feeTotal : int64<MeasureProduct<Cent, MeasureOne>>
Returns: Percent
|
calculates the fee total as a percentage of the principal, for further calculation (weighting payments made when apportioning to fee and principal)
|
Full Usage:
generate sp settlementDay trimEnd actualPayments
Parameters:
Parameters
settlementDay : SettlementDay
trimEnd : bool
actualPayments : Map<int<MeasureProduct<OffsetDay, MeasureOne>>, ActualPayment array>
Returns: GenerationResult
|
generates an amortisation schedule and final statistics
|
Full Usage:
getBalanceStatus principalBalance
Parameters:
int64<MeasureProduct<Cent, MeasureOne>>
Returns: BalanceStatus
|
gets the balance status based on the principal balance
|
Full Usage:
isSettledWithinGracePeriod sp settlementDay
Parameters:
Parameters
settlementDay : SettlementDay
Returns: bool
|
determines whether a schedule is settled within any grace period (e.g. no interest may be due if settlement is made within three days of the advance)
|
Full Usage:
markMissedPaymentsAsLate schedule
Parameters:
Map<int<MeasureProduct<OffsetDay, MeasureOne>>, ScheduleItem>
Returns: Map<int<MeasureProduct<OffsetDay, MeasureOne>>, ScheduleItem>
|
modifies missed payments or underpayments to reflect whether they are paid later in full or part or not at all within the payment window note: this is useful for credit reporting so as not to penalise those who pay late rather than not at all
|
Active patterns
Active pattern |
Description
|
Full Usage:
(|NotPaidAtAll|SomePaid|FullyPaid|) (actualPaymentTotal, paymentDueTotal)
Parameters:
int64<MeasureProduct<Cent, MeasureOne>>
paymentDueTotal : int64<MeasureProduct<Cent, MeasureOne>>
Returns: Choice<unit, int64<MeasureProduct<Cent, MeasureOne>>, unit>
|
pattern matching for payments due vs payments made
|