PHPackages                             kaurikk/loan-payment-period - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. kaurikk/loan-payment-period

AbandonedArchivedLibrary[Utility &amp; Helpers](/categories/utility)

kaurikk/loan-payment-period
===========================

\[Loan payment period calculation library\]

0.0.2(9y ago)15931MITPHPPHP &gt;=7.1

Since Apr 20Pushed 9y agoCompare

[ Source](https://github.com/kaurikk/loan-payment-period)[ Packagist](https://packagist.org/packages/kaurikk/loan-payment-period)[ RSS](/packages/kaurikk-loan-payment-period/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependencies (2)Versions (3)Used By (1)

[![Build Status](https://camo.githubusercontent.com/fb7661c8b1e86aae6904e50a7a94d8bc65f91718be7f3c7c7488102f5b4d8163/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f6b617572696b6b2f6c6f616e2d7061796d656e742d706572696f642f6261646765732f6275696c642e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/kaurikk/loan-payment-period/build-status/master) [![Scrutinizer Code Quality](https://camo.githubusercontent.com/e1bc10c6c0ab4a30b359825702a5d05fb46fed421b52898322bb8c451d9428ec/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f6b617572696b6b2f6c6f616e2d7061796d656e742d706572696f642f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/kaurikk/loan-payment-period/?branch=master) [![Code Coverage](https://camo.githubusercontent.com/e83e442faaf910cc4aa36a965eb760f945f82e596754bd3c03dbf7f93b405dcc/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f6b617572696b6b2f6c6f616e2d7061796d656e742d706572696f642f6261646765732f636f7665726167652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/kaurikk/loan-payment-period/?branch=master)[![SensioLabsInsight](https://camo.githubusercontent.com/45ae62225aba0da7799ae0c2dc9bcee003ec2f29d443049c146802e946f96d39/68747470733a2f2f696e73696768742e73656e73696f6c6162732e636f6d2f70726f6a656374732f30656433303266662d396539332d343434352d386663322d6263656332323761666135372f6d696e692e706e67)](https://insight.sensiolabs.com/projects/0ed302ff-9e93-4445-8fc2-bcec227afa57)

loan-payment-period
===================

[](#loan-payment-period)

Library to generate loan payment periods based on payment schedule. Contains 3 main parts:

- PaymentPeriodsFactory - generates payment periods based on payment schedule
- PaymentPeriods - holds payment periods collection
- Period - single period

Basic usage
-----------

[](#basic-usage)

See [more](https://github.com/kaurikk/loan-payment-schedule/blob/master/README.md#basic-usage) about PaymentSchedule.

```
$paymentPeriods = PaymentPeriodsFactory::generate($paymentSchedule);

// How many periods are in collection
$numberOfPayments = $paymentPeriods->getNoOfPeriods();

// Get array of Periods from collection
$periods = $paymentPeriods->getPeriods();

// Get first period from Periods array
$firstPeriod = current($periods);

// Period start date
$firstPeriod->getStart();
// Period end date
$firstPeriod->getEnd();
```

Periods can have two different type of length:

- Average: for monthly payements it's 30
- Exact: exact different between start and end of period (from 28 to 31 or even more is adjusting logic is used)

```
// How long is period - average (days)
$firstPeriod->getAvgLength();

// How long is period - exact (days)
$firstPeriod->getExactLength();
```

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity49

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~7 days

Total

2

Last Release

3301d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/e1f1307c92c36d8ba3c920e818cd21370ba97b63c9bc9914ae4e61d5955de2b5?d=identicon)[kaurikk](/maintainers/kaurikk)

---

Top Contributors

[![kaurikk](https://avatars.githubusercontent.com/u/4194333?v=4)](https://github.com/kaurikk "kaurikk (19 commits)")

---

Tags

loanphp

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/kaurikk-loan-payment-period/health.svg)

```
[![Health](https://phpackages.com/badges/kaurikk-loan-payment-period/health.svg)](https://phpackages.com/packages/kaurikk-loan-payment-period)
```

###  Alternatives

[aucor/dynamic-mo-loader

Better text domain loading with object cache support for WordPress

4554.1k1](/packages/aucor-dynamic-mo-loader)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
