private function runGenerateFactorPieChart($w, $h, $factor, $file) { $chart = new PieChart($w, $h); foreach ($this->mitgliederFactorCount[$factor] as $label => $count) { if (!empty($label)) { $chart->addData(new Chart_Data($label, $count)); } } $chart->plot($file); }