You are here

function pData::getSerieAverage in Visitors 7.2

Same name and namespace in other branches
  1. 7 pChart/class/pData.class.php \pData::getSerieAverage()
2 calls to pData::getSerieAverage()
pData::getCoefficientOfVariation in pChart/class/pData.class.php
pData::getStandardDeviation in pChart/class/pData.class.php

File

pChart/class/pData.class.php, line 271

Class

pData

Code

function getSerieAverage($Serie) {
  if (isset($this->Data["Series"][$Serie])) {
    $SerieData = $this
      ->stripVOID($this->Data["Series"][$Serie]["Data"]);
    return array_sum($SerieData) / sizeof($SerieData);
  }
  else {
    return NULL;
  }
}