Merge branch 'ent-7473-11796-mala-representacion-de-percentil-en-graficas-personalizadas' into 'develop'
fixed error with percentiles in graphs See merge request artica/pandorafms!4312
This commit is contained in:
commit
b02ecc7cae
|
@ -3299,8 +3299,10 @@ function extract_column($array, $column)
|
|||
|
||||
function get_percentile($percentile, $array)
|
||||
{
|
||||
global $config;
|
||||
|
||||
sort($array);
|
||||
$index = (($percentile / 100) * count($array));
|
||||
$index = (($config['percentil'] / 100) * count($array));
|
||||
|
||||
if (floor($index) == $index) {
|
||||
$result = (($array[($index - 1)] + $array[$index]) / 2);
|
||||
|
|
Loading…
Reference in New Issue