You can install the package via composer:
composer require apxcde/loan-amortization
use Apxcde\LoanAmortization\LoanAmortization;
$amount = 200000;
$termYears = 5;
$annualInterestRate = 12;
$loan_data = [
'loan_amount' => (float) $amount,
'term_years' => $termYears,
'interest' => $annualInterestRate,
'term_months' => $termYears * 12,
'starting_date' => Carbon::now(),
'remaining_months' => $termYears * 12,
];
$loan_calculation = new LoanAmortization($loan_data);
composer test
Please see CHANGELOG for more information on what has changed recently.
Please see CONTRIBUTING for details.
Please review our security policy on how to report security vulnerabilities.
The MIT License (MIT). Please see License File for more information.