PHPackages                             blainesch/prettyarray - 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. blainesch/prettyarray

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

blainesch/prettyarray
=====================

Manipulate arrays similar to Ruby.

1.0.5(12y ago)1019.2k1The BSD LicensePHPPHP &gt;=5.3.3

Since Aug 21Pushed 11y ago2 watchersCompare

[ Source](https://github.com/BlaineSch/prettyArray)[ Packagist](https://packagist.org/packages/blainesch/prettyarray)[ Docs](https://github.com/BlaineSch/prettyArray)[ RSS](/packages/blainesch-prettyarray/feed)WikiDiscussions master Synced 2w ago

READMEChangelogDependenciesVersions (9)Used By (0)

PrettyArray
===========

[](#prettyarray)

A object oriented approach to handling arrays in PHP. It attempts to combine Ruby (enumerator/array/hash) methods as well as built in PHP functions.

[![Build Status](https://camo.githubusercontent.com/f7c9959cbc358df3a04d1afd46f13563d8887105e41af8f97e36b3c3dc0a20fd/68747470733a2f2f7365637572652e7472617669732d63692e6f72672f626c61696e657363682f70726574747941727261792e706e673f6272616e63683d6d6173746572)](http://travis-ci.org/blainesch/prettyArray)

Example 1
---------

[](#example-1)

```

```

```
Array
(
    [0] => Array
        (
            [0] => 3
            [1] => 6
        )

    [1] => Array
        (
            [0] => 1
            [1] => 4
        )

    [2] => Array
        (
            [0] => 2
            [1] => 5
        )
)

```

More Examples
-------------

[](#more-examples)

More examples can be found inside of the "/examples" directory in markdown format which is viewable on Github.

Installation
------------

[](#installation)

### GIT

[](#git)

```
git clone git://github.com/BlaineSch/prettyArray.git
# OR
git submodule add git://github.com/BlaineSch/prettyArray.git
```

### Composer

[](#composer)

```
"require": {
    "blainesch/prettyarray": "1.0.0"
}
```

```
php compooser.phar install
```

Requirements
------------

[](#requirements)

- [PHP 5.3+](http://php.net/downloads.php)

Contributing
------------

[](#contributing)

### Requirements

[](#requirements-1)

- [PHP 5.3+](http://php.net/downloads.php)
- [PHPUnit](http://www.phpunit.de/manual/3.6/en/installation.html/)

### Testing

[](#testing)

Before making any pull requests please verify that your methods pass the current unit tests.

```
cd PrettyArray && phpunit

```

```
PHPUnit 3.6.12 by Sebastian Bergmann.

Configuration read from /Users/blaineschmeisser/Sites/devup/PrettyArray/phpunit.xml

...............................................................  63 / 159 ( 39%)
............................................................... 126 / 159 ( 79%)
.................................

Time: 1 second, Memory: 10.00Mb

OK (159 tests, 180 assertions)

```

### Test Files

[](#test-files)

- [PrettyArray Test](tests/prettyArrayTest.php) - Tests the core functionality of PrettyArray.
- [Enumerator Test](tests/enumeratorTest.php) - Tests all the core methods inside of enumerator.
- [Exception Test](tests/exceptionTest.php) - Tests all methods specifically if they are handling exceptions correctly.

###  Health Score

33

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity27

Limited adoption so far

Community5

Small or concentrated contributor base

Maturity63

Established project with proven stability

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 ~3 days

Total

6

Last Release

4681d ago

PHP version history (2 changes)1.0.0PHP &gt;=5.3.10

1.0.4PHP &gt;=5.3.3

### Community

Maintainers

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

---

Tags

arrayenumeratorunderscoreruby

### Embed Badge

![Health badge](/badges/blainesch-prettyarray/health.svg)

```
[![Health](https://phpackages.com/badges/blainesch-prettyarray/health.svg)](https://phpackages.com/packages/blainesch-prettyarray)
```

###  Alternatives

[doctrine/collections

PHP Doctrine Collections library that adds additional functionality on top of PHP arrays.

6.0k423.8M1.4k](/packages/doctrine-collections)[symfony/property-access

Provides functions to read and write from/to an object or array using a simple string notation

2.8k309.5M3.1k](/packages/symfony-property-access)[nette/utils

🛠 Nette Utils: lightweight utilities for string &amp; array manipulation, image handling, safe JSON encoding/decoding, validation, slug or strong password generating etc.

2.1k417.9M1.7k](/packages/nette-utils)[league/config

Define configuration arrays with strict schemas and access values with dot notation

565323.7M35](/packages/league-config)[cuyz/valinor

Dependency free PHP library that helps to map any input into a strongly-typed structure.

1.5k13.2M162](/packages/cuyz-valinor)[marc-mabe/php-enum

Simple and fast implementation of enumerations with native PHP

50458.3M104](/packages/marc-mabe-php-enum)

PHPackages © 2026

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