Download the PHP package soandso/grouping without Composer
On this page you can find all versions of the php package soandso/grouping. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package grouping
Grouping - PHP library for generating grouped statistical series
The library allows you to create grouped out of simple statistical series, subject to the use of large amounts of data.
Setup
Add the library to your composer.json
file in your project:
Use composer to install the library:
Composer will install Grouping inside your vendor folder. Then you can add the following to your .php files to use the library with Autoloading.
You can also use composer on the command line to require and install Grouping:
Minimum Requirements
- PHP 7
Description
To get started, you need to create an object of the core class of the library Grouping:
Next, you need to add the source data for the calculation:
$source_data is the source data presented in the view of a simply non-associative array.
The peculiarity of the library is that you can pull out the method of adding source data many times.
This may be important when dealing with large amounts of data. For example, you can upload a large file in parts Example,
After this construction of the grouped statistical series, you need to call the method buildGss:
$output - parameter defining the format of the returned result. The parameter is required and can take such values as 'array', 'json' and 'file'. $path_file - parameter, defines the system path to the directory where the result file will be written. The parameter is optional. Must end with a slash '/'. Example:
As a result of constructing a guided statistical series, the library presents the following data: the number of partial intervals, the values at the boundaries of the partial intervals, interval frequencies, random values at the midpoints of partial intervals, interval frequencies. For example, the output in array format will look like:
Standards
Grouping conforms to the following standards:
- PSR-1 - Basic coding standard (http://www.php-fig.org/psr/psr-1/)
- PSR-4 - Autoloader (http://www.php-fig.org/psr/psr-4/)
- PSR-12 - Extended coding style guide (http://www.php-fig.org/psr/psr-12/)
License
Grouping is licensed under the GPLv2 (https://www.gnu.org/licenses/old-licenses/gpl-2.0.html) License.