PHP Classes

PHP Statistics Functions: Parse numbers from text data and return statistics

Recommend this page to a friend!
  Info   View files Example   View files View files (2)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not yet rated by the usersTotal: 256 All time: 7,829 This week: 148Up
Version License PHP version Categories
raw2table 1.0.0Freeware5Algorithms, PHP 5, Statistics, Parsers


This class can parse numbers from text data and return statistics.

It takes a string with a series of numbers and several computes statistics from those numbers.

The class can return statistics values like the smallest and largest value, the width of the number of range, the total number of classes, the distance frequency table, etc..

Innovation Award
PHP Programming Innovation award nominee
April 2018
Number 6
Some applications need to take numeric values eventually entered in spreadsheets and process them somehow in a useful way.

This package can take numbers in a text string and process them by calculating several types of supported statatistic functions.

Manuel Lemos
Picture of Aditya Rahman
  Performance   Level  
Name: Aditya Rahman <contact>
Classes: 1 package by
Country: Indonesia Indonesia
Age: 25
All time rank: 394766 in Indonesia Indonesia
Week rank: 398 Up11 in Indonesia Indonesia Up
Innovation award
Innovation award
Nominee: 1x


            td,th {
                padding: 5px;
        <form method="post">
            <textarea name="raw" rows="20" cols="100"></textarea><br/>
            <input type="submit">

include "raw2table.php";
<table cellspacing="0" border="1">
                <th>Frekuensi Kumulatif</th>
= new raw2table();
$data = $obj->convert_data($_POST['raw']);
$row = 0;
                foreach (
$obj->get_freq_dist_table($data) as $item) :
                    <td align="center"><?=$item['min']?> - <?=$item['max']?></td>
                    <td align="center"><?=$item['freq']?></td>
                    <td align="center">
+= $obj->get_freq_dist_table($data)[$row]['freq'];
echo "<br/>";
"Total data : ".$obj->get_total_data($data)."<br/>";
"Minimal data : ".$obj->get_min($data)."<br/>";
"Maksimal data : ".$obj->get_max($data)."<br/>";
"Rentang data : ".$obj->get_range($data)."<br/>";
"Jumlah kelas : ".$obj->get_many_classes($data)."<br/>";
"Panjang per-kelas : ".$obj->get_long_class($data)."<br/>";

  Files folder image Files  
File Role Description
Accessible without login Plain text file raw2table-ex.php Example Example script
Plain text file raw2table.php Class Class source

 Version Control Unique User Downloads Download Rankings  
This week:0
All time:7,829
This week:148Up