2017 © Pedro Peláez
 

library transpose

A utility package adding a transpose function to multi-dimensional arrays, interchanging array indices.

image

petemc/transpose

A utility package adding a transpose function to multi-dimensional arrays, interchanging array indices.

  • Tuesday, June 7, 2016
  • by petemcfarlane
  • Repository
  • 0 Watchers
  • 1 Stars
  • 10 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

Build Status Latest Stable Version License, (*1)

transpose

Adds transpose function for multi-dimensional arrays, interchanging row/column indices., (*2)

Example

<?php

use function PeteMc\Transpose\transpose;

$input = [
    'names' => ['adam', 'ben', 'claire'],
    'ages' => [24, 32, 52],
    'emails' => ['adam@example.com', 'ben@example.com', 'claire@example.com'],
];

$transposed = transpose($input);

/*
$transposed is equal to
[
    ['adam', 24, 'adam@example.com'],
    ['ben', 32, 'ben@example.com'],
    ['claire', 52, 'claire@example.com'],
];
*/

The Versions

07/06 2016

dev-master

9999999-dev

A utility package adding a transpose function to multi-dimensional arrays, interchanging array indices.

  Sources   Download

MIT

The Development Requires

by Pete McFarlane

07/06 2016

v1.0.0

1.0.0.0

A utility package adding a transpose function to multi-dimensional arrays, interchanging array indices.

  Sources   Download

MIT

The Development Requires

by Pete McFarlane