Python library for calculating amortizations and generating amortization schedules
Project description
amortization
Python library for calculating amortizations and generating amortization schedules
Demo
Install
pip install amortization
Usage
Python
Amortization Amount
from amortization import calculate_amortization_amount
amount = calculate_amortization_amount(150_000, 0.1, 36)
Amortization Schedule
from amortization import amortization_schedule
for number, amount, interest, principal, balance in amortization_schedule(150_000, 0.1, 36):
print()
Amortization Schedule (using tabulate)
from amortization import amortization_schedule
from tabulate import tabulate
table = (x for x in amortization_schedule(150_000, 0.1, 36))
print(
tabulate(
table,
headers=["Number", "Amount", "Interest", "Principal", "Balance"],
floatfmt=",.2f",
numalign="right"
)
)
Command line
amortization -h
usage: amortization [-h] -P PRINCIPAL -n PERIOD -r INTEREST_RATE [-s]
Python library for calculating amortizations and generating amortization
schedules
optional arguments:
-h, --help show this help message and exit
-P PRINCIPAL, --principal PRINCIPAL
Principal amount
-n PERIOD, --period PERIOD
Total number of periods
-r INTEREST_RATE, --interest-rate INTEREST_RATE
Interest rate per period
-s, --schedule Generate amortization schedule
Dependencies
Author
References
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
amortization-0.1.0rc1.tar.gz
(2.9 kB
view hashes)
Built Distribution
Close
Hashes for amortization-0.1.0rc1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7ea09b6217bd279c0dbac752914ac46a1ac8e47c580e88dd903c491ea1f2be2c |
|
MD5 | 3259d281f91ffe3fed66893b6593ac58 |
|
BLAKE2b-256 | 5059576a58f3e6a9f570edf60f71fe99fb0925a5e39588e6eea28ccab776059c |