本文整理汇总了PHP中x_axis_labels类的典型用法代码示例。如果您正苦于以下问题:PHP x_axis_labels类的具体用法?PHP x_axis_labels怎么用?PHP x_axis_labels使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了x_axis_labels类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: buildChart
protected function buildChart()
{
$chart = $this->getGraph();
// $title = new title('No data');
// $title->set_style('{font-size: 25px;}');
// $chart->set_title($title);
//
$area = $this->createArea();
$dotValues = $this->buildDotValues('#f58615');
$area->set_values($dotValues);
// add the area object to the chart:
$chart->add_element($area);
$y_axis = $this->createYAxis();
$y_axis->set_range(max(0, min($this->values) - 1), max($this->values) + 1);
$y_axis->set_steps(ceil(max($this->values) / 4));
//y_axis legend
$y_legend = new y_legend('Viewers');
$y_legend->set_style('color: #515151; font-size: 12px;');
$chart->set_y_legend($y_legend);
$x_axis = $this->createXAxis();
$x_axis->set_steps(1);
$x_labels = new x_axis_labels();
$x_labels->set_labels(array_values($this->labels));
//$x_labels->set_steps( 1 );
// Add the X Axis Labels to the X Axis
$x_axis->set_labels($x_labels);
$chart->add_y_axis($y_axis);
$chart->x_axis = $x_axis;
return $chart;
}
示例2: get_laba_rugi
/**
* Generates data for OFC2 line chart in json format
*
* @return void
*/
public function get_laba_rugi()
{
$this->load->plugin('ofc2');
$this->load->model('jurnal_model');
$model_data = $this->jurnal_model->get_laba_rugi_data();
$bulan_data = array("Jan", "Feb", "Mar", "Apr", "Mei", "Jun", "Jul", "Agu", "Sep", "Okt", "Nov", "Des");
for ($i = date('n') + 1; $i <= 12; $i++) {
$pendapatan_kredit = isset($model_data[$i][date('Y') - 1][4][0]) ? $model_data[$i][date('Y') - 1][4][0] : 0;
$pendapatan_debit = isset($model_data[$i][date('Y') - 1][4][1]) ? $model_data[$i][date('Y') - 1][4][1] : 0;
$beban_kredit = isset($model_data[$i][date('Y') - 1][5][0]) ? $model_data[$i][date('Y') - 1][5][0] : 0;
$beban_debit = isset($model_data[$i][date('Y') - 1][5][1]) ? $model_data[$i][date('Y') - 1][5][1] : 0;
$data[] = $pendapatan_kredit - $pendapatan_debit - ($beban_debit - $beban_kredit);
$thn = date('y') - 1;
$thn = strlen($thn) == 1 ? '0' . $thn : $thn;
$x_data[] = $bulan_data[$i - 1] . "'" . $thn;
}
for ($i = 1; $i <= date('n'); $i++) {
$pendapatan_kredit = isset($model_data[$i][date('Y')][4][0]) ? $model_data[$i][date('Y')][4][0] : 0;
$pendapatan_debit = isset($model_data[$i][date('Y')][4][1]) ? $model_data[$i][date('Y')][4][1] : 0;
$beban_kredit = isset($model_data[$i][date('Y')][5][0]) ? $model_data[$i][date('Y')][5][0] : 0;
$beban_debit = isset($model_data[$i][date('Y')][5][1]) ? $model_data[$i][date('Y')][5][1] : 0;
$data[] = $pendapatan_kredit - $pendapatan_debit - ($beban_debit - $beban_kredit);
$x_data[] = $bulan_data[$i - 1] . "'" . date('y');
}
$max = (int) max($data);
$maxlen = strlen($max);
$up = round($max, -($maxlen - 1));
$min = (int) min($data);
$minlen = strlen($min);
$down = round($min, -($minlen - 1));
$abs_max = (int) max(abs($max), abs($min));
$len = strlen($abs_max);
$round = round($abs_max, -($len - 1));
$step = '1' . substr($round, 1);
$up = $max > $up ? $up + $step : $up;
$down = $min < $down ? $down - $step : $down;
$d = new hollow_dot();
$d->size(4)->halo_size(1)->colour('#668053');
$line = new line();
$line->set_values($data);
$line->set_default_dot_style($d);
$line->set_width(5);
$line->set_colour('#7491a0');
$x_labels = new x_axis_labels();
$x_labels->set_labels($x_data);
$x = new x_axis();
$x->set_labels($x_labels);
$x->set_grid_colour('#bfb8b3');
$y = new y_axis();
$y->set_grid_colour('#bfb8b3');
$y->set_range($down, $up, $step);
$chart = new open_flash_chart();
$chart->add_element($line);
$chart->set_x_axis($x);
$chart->set_y_axis($y);
$chart->set_bg_colour('#FFFFFF');
echo $chart->toPrettyString();
}
示例3: set_labels_from_array
function set_labels_from_array($a)
{
$x_axis_labels = new x_axis_labels();
$x_axis_labels->set_labels($a);
$this->labels = $x_axis_labels;
if (isset($this->steps)) {
$x_axis_labels->set_steps($this->steps);
}
}
示例4: setUpGraph
protected function setUpGraph()
{
parent::setUpGraph();
$aDataSets = $this->getDataSets();
// if no data, or only one data point, we don't display the graph
if (count($this->xLabels) <= 1) {
return false;
}
$chart = $this->getGraph();
//set up the axes
$y_axis = $this->createYAxis();
$y_axis->set_range(max(0, $this->getMinYValue() - 1), $this->getMaxYValue() + 1);
$y_axis->set_steps(ceil($this->getMaxYValue() / 4));
$y_axis->set_label_text("#val#" . $this->yUnit);
//y_axis legend
$y_legend = new y_legend('Viewers');
$y_legend->set_style('color: #515151; font-size: 12px;');
$chart->set_y_legend($y_legend);
$x_axis = $this->createXAxis();
$x_values = $this->xLabels;
$xSteps = 5;
if (count($x_values) < $xSteps) {
$xSteps = count($x_values);
} else {
// hack around the set_steps that doesn't seem to work for X axis
foreach ($x_values as $i => &$xValue) {
if ($i % $xSteps != 0) {
$xValue = '';
}
}
}
$x_axis->set_steps($xSteps);
$x_labels = new x_axis_labels();
$x_labels->set_labels($x_values);
// Add the X Axis Labels to the X Axis
$x_axis->set_labels($x_labels);
$chart->add_y_axis($y_axis);
$chart->x_axis = $x_axis;
$oColorHelper = new Graph_DataSetColorsHelper();
foreach ($aDataSets as $aDataSet) {
$values = $aDataSet['values'];
$name = $aDataSet['name'];
$aColors = $oColorHelper->getNextColors();
$dotValues = $this->buildDotValues($aColors['line'], $values, $name);
$area = $this->createArea($aColors['line'], $aColors['fill']);
$area->set_fill_alpha("0.1");
$area->set_values($dotValues);
$area->set_text($name);
// add the area object to the chart:
$chart->add_element($area);
}
return $chart;
}
示例5: get_statistic
function get_statistic()
{
$this->load->library('OpenFlashChartLib', NULL, 'OFCL');
$data_1 = array();
$data_2 = array();
// generate 7 data points
for ($i = 0; $i <= 7; $i++) {
$x = mktime(0, 0, 0, date("m"), date("d") - $i, date('Y'));
$param['sms_date'] = date('Y-m-d', mktime(0, 0, 0, date("m"), date("d") - $i, date("Y")));
$param['user_id'] = $this->session->userdata('id_user');
$y = $this->Kalkun_model->get_sms_used('date', $param);
$data_1[] = new scatter_value($x, $y);
$data_2[] = $y;
}
$def = new solid_dot();
$def->size(4)->halo_size(0)->colour('#21759B')->tooltip('#date:d M y#<br>#val# SMS');
$line = new scatter_line('#21759B', 3);
$line->set_values($data_1);
$line->set_default_dot_style($def);
$line->set_key("SMS used in last 7 days", 10);
$x = new x_axis();
// grid line and tick every 10
$x->set_range(mktime(0, 0, 0, date("m"), date("d") - 7, date('Y')), mktime(0, 0, 0, date("m"), date("d"), date('Y')));
// show ticks and grid lines for every day:
$x->set_steps(86400);
$labels = new x_axis_labels();
// tell the labels to render the number as a date:
$labels->text('#date:M-d#');
// generate labels for every day
$labels->set_steps(86400);
// only display every other label (every other day)
$labels->visible_steps(1);
$labels->rotate(45);
// finally attach the label definition to the x axis
$x->set_labels($labels);
$y = new y_axis();
if (max($data_2) > 0) {
$max = max($data_2);
} else {
$max = 10;
}
$y->set_range(0, $max, 10);
$chart = new open_flash_chart();
//$chart->set_title( $title );
$chart->add_element($line);
$chart->set_x_axis($x);
$chart->set_y_axis($y);
echo $chart->toPrettyString();
}
示例6: render
/**
* Method to render a statistical chart using Open Flash library.
*
* @return false if someting wrong
*/
function render()
{
$values = array();
foreach ($this->values as $number_variable => $variable) {
$values[$number_variable] = (int) $variable;
}
$area = new area();
$area->set_default_dot_style(new hollow_dot());
$area->set_colour('#5B56B6');
$area->set_fill_alpha(0.4);
$area->set_values($values);
$area->set_key('Values', 12);
$x_labels = new x_axis_labels();
$x_labels->set_steps(1);
$x_labels->set_vertical();
$x_labels->set_colour('#A2ACBA');
$x_labels->set_labels($this->legend);
$x = new x_axis();
$x->set_colour('#A2ACBA');
$x->set_grid_colour('#D7E4A3');
$x->set_offset(false);
$x->set_steps(1);
// Add the X Axis Labels to the X Axis
$x->set_labels($x_labels);
$y = new y_axis();
$y_max = max($values) > 0 ? max($values) : 4;
$y_mod = (int) ($y_max / 4 + 1);
$y_max += $y_mod - $y_max % $y_mod;
$y->set_range(0, $y_max, $y_mod);
$y->labels = null;
$y->set_offset(false);
$chart = new open_flash_chart();
$chart->set_x_axis($x);
$chart->add_y_axis($y);
$chart->add_element($area);
return $chart;
}
示例7: _render_statistic
function _render_statistic($x = array(), $yout = array(), $yin = array(), $type = 'bar', $points)
{
$this->load->helper('date');
$this->load->library('OpenFlashChartLib', NULL, 'OFCL');
$data_1 = array();
$data_2 = array();
$data_3 = array();
switch ($type) {
case 'bar':
for ($i = 0; $i <= $points; $i++) {
$data_1[$i] = $x[$i];
$data_2[$i] = (int) $yout[$i];
// force to integer
$data_3[$i] = (int) $yin[$i];
// force to integer
}
$data_1 = array_reverse($data_1);
$data_2 = array_reverse($data_2);
$data_3 = array_reverse($data_3);
$bar_1 = new bar();
$bar_1->set_values($data_3);
$bar_1->set_colour('#639F45');
$bar_1->key(lang('kalkun_incoming_sms'), 10);
$bar_1->set_tooltip('#x_label#<br>#val# SMS');
//$bar_1->set_key("SMS used in last 7 days", 10);
$bar_2 = new bar();
$bar_2->set_values($data_2);
$bar_2->set_colour('#21759B');
$bar_2->key(lang('kalkun_outgoing_sms'), 10);
$bar_2->set_tooltip('#x_label#<br>#val# SMS');
$x = new x_axis();
$labels = new x_axis_labels();
$labels->set_labels($data_1);
$labels->set_steps(1);
$x->set_labels($labels);
$y = new y_axis();
$max = max(max($data_2), max($data_3));
if ($max < 10) {
$max = 10;
}
$max = ceil($max / 5) * 5;
$range = ceil($max / 5);
$range = ceil($range / 10) * 10;
$y->set_range(0, $max, $range);
$element1 = $bar_1;
$element2 = $bar_2;
break;
case 'line':
for ($i = 0; $i <= 7; $i++) {
$data_1[$i] = new scatter_value($x[$i], $yin[$i]);
$data_2[$i] = new scatter_value($x[$i], $yout[$i]);
$data_3[$i] = (int) $yin[$i];
$data_4[$i] = (int) $yout[$i];
}
$def = new solid_dot();
$def->size(4)->halo_size(0)->colour('#21759B')->tooltip('#date:d M y#<br>#val# SMS');
$line_1 = new scatter_line('#639F45', 3);
$line_1->set_values($data_1);
$line_1->set_default_dot_style($def);
$line_1->set_key("Incoming SMS", 10);
$line_2 = new scatter_line('#21759B', 3);
$line_2->set_values($data_2);
$line_2->set_default_dot_style($def);
$line_2->set_key("Outgoing SMS", 10);
$x = new x_axis();
// grid line and tick every 10
$x->set_range(mktime(0, 0, 0, date("m"), date("d") - 7, date('Y')), mktime(0, 0, 0, date("m"), date("d"), date('Y')));
// show ticks and grid lines for every day:
$x->set_steps(86400);
$labels = new x_axis_labels();
// tell the labels to render the number as a date:
$labels->text('#date:M-d#');
// generate labels for every day
$labels->set_steps(86400);
// only display every other label (every other day)
$labels->visible_steps(1);
$labels->rotate(45);
// finally attach the label definition to the x axis
$x->set_labels($labels);
$y = new y_axis();
$max = max(max($data_3), max($data_4));
if ($max < 1) {
$max = 10;
}
$y->set_range(0, $max, round($max / 100) * 10);
$element1 = $line_1;
$element2 = $line_2;
break;
}
$chart = new open_flash_chart();
$chart->add_element($element1);
$chart->add_element($element2);
$chart->set_x_axis($x);
$chart->set_y_axis($y);
echo $chart->toPrettyString();
}
示例8: array
');
$deposits = array();
$withdrawals = array();
$weeks = array();
while ($row = mysql_fetch_assoc($result)) {
$weeks[] = date('d.m.Y', $row['stamp']);
$deposits[] = round($row['deposits'], 2);
$withdrawals[] = -round($row['withdrawals'], 2);
}
//lines
$line1 = new line();
$line1->set_values($deposits);
$line1->set_colour('#00FF00');
$line2 = new line();
$line2->set_values($withdrawals);
$line2->set_colour('#FF0000');
//axises
$axis_x = new x_axis();
$axis_x_labels = new x_axis_labels();
$axis_x_labels->set_labels($weeks);
$axis_x->set_labels($axis_x_labels);
$axis_y = new y_axis();
$axis_y->range(0, max(max($deposits), max($withdrawals)), 1000);
//chart
$chart = new open_flash_chart();
$chart->set_y_axis($axis_y);
$chart->set_x_axis($axis_x);
$chart->add_element($line1);
$chart->add_element($line2);
$chart->set_bg_colour('#FFFFFF');
echo $chart->toPrettyString();
示例9: explode
$tmp = explode(" ", $line);
$datalist[] = 1 * $tmp[1];
$labellist[] = $tmp[0];
}
//Prevent error on no data
if (count($datalist < 1)) {
$datalist[] = 0;
$labellist[] = 0;
}
$title = new title("Checking account forecast");
$default_dot = new dot();
$default_dot->tooltip('$#val#');
$line = new line();
$line->set_values($datalist);
$line->set_default_dot_style($default_dot);
$x_labels = new x_axis_labels();
$x_labels->rotate(45);
$x_labels->set_labels($labellist);
$x_labels->set_steps(3);
$x = new x_axis();
$x->set_labels($x_labels);
$y = new y_axis();
$y->set_range(min(min($datalist) - 10, 0), round(max($datalist) * 1.1));
$y->set_label_text("\$#val#");
$chart = new open_flash_chart();
$chart->set_title($title);
$chart->add_element($line);
$chart->set_x_axis($x);
$chart->set_y_axis($y);
$chart->set_bg_colour('#FFFFFF');
echo $chart->toPrettyString();
示例10: GetRenderContent
//.........这里部分代码省略.........
$aLabels[$iRow] = strip_tags($sHtmlValue);
$aGroupBy[$iRow] = (int) $aRow['_itop_count_'];
$iTotalCount += $aRow['_itop_count_'];
}
$aData = array();
$aChartLabels = array();
$maxValue = 0;
foreach ($aGroupBy as $iRow => $iCount) {
$oBarValue = new bar_value($iCount);
$oBarValue->on_click("ofc_drill_down_{$sId}");
$aData[] = $oBarValue;
if ($iCount > $maxValue) {
$maxValue = $iCount;
}
$aChartLabels[] = html_entity_decode($aLabels[$iRow], ENT_QUOTES, 'UTF-8');
}
$oYAxis = new y_axis();
$aMagicValues = array(1, 2, 5, 10);
$iMultiplier = 1;
$index = 0;
$iTop = $aMagicValues[$index % count($aMagicValues)] * $iMultiplier;
while ($maxValue > $iTop) {
$index++;
$iTop = $aMagicValues[$index % count($aMagicValues)] * $iMultiplier;
if ($index % count($aMagicValues) == 0) {
$iMultiplier = $iMultiplier * 10;
}
}
//echo "oYAxis->set_range(0, $iTop, $iMultiplier);\n";
$oYAxis->set_range(0, $iTop, $iMultiplier);
$oChart->set_y_axis($oYAxis);
$oChartElement->set_values($aData);
$oXAxis = new x_axis();
$oXLabels = new x_axis_labels();
// set them vertical
$oXLabels->set_vertical();
// set the label text
$oXLabels->set_labels($aChartLabels);
// Add the X Axis Labels to the X Axis
$oXAxis->set_labels($oXLabels);
$oChart->set_x_axis($oXAxis);
}
break;
case 'pie':
default:
$oChartElement = new pie();
$oChartElement->set_start_angle(35);
$oChartElement->set_animate(true);
$oChartElement->set_tooltip('#label# - #val# (#percent#)');
$oChartElement->set_colours(array('#FF8A00', '#909980', '#2C2B33', '#CCC08D', '#596664'));
if (isset($aExtraParams['group_by'])) {
if (isset($aExtraParams['group_by_label'])) {
$oGroupByExp = Expression::FromOQL($aExtraParams['group_by']);
$sGroupByLabel = $aExtraParams['group_by_label'];
} else {
// Backward compatibility: group_by is simply a field id
$sAlias = $this->m_oFilter->GetClassAlias();
$oGroupByExp = new FieldExpression($aExtraParams['group_by'], $sAlias);
$sGroupByLabel = MetaModel::GetLabel($this->m_oFilter->GetClass(), $aExtraParams['group_by']);
}
$aGroupBy = array();
$aGroupBy['grouped_by_1'] = $oGroupByExp;
$sSql = $this->m_oFilter->MakeGroupByQuery($aQueryParams, $aGroupBy, true);
$aRes = CMDBSource::QueryToArray($sSql);
$aGroupBy = array();
$aLabels = array();
示例11: index2Action
public function index2Action()
{
$this->_helper->layout->disableLayout();
include 'open-flash-chart.php';
$db = Zend_Registry::get('db');
$select = $db->select();
$select->from('report', array('left(create_date,10) as date', 'count(*)'))->where('report.campaign_id = 3')->where("report.state = 'APPROVED'")->group('date')->order('date')->limit(0);
$results = $db->fetchAll($select);
$array_data = array();
$array_create_date = array();
foreach ($results as $result) {
array_push($array_data, (int) $result["count(*)"]);
array_push($array_create_date, $result["date"]);
}
$title = new title("BugsLock Reports By Day");
$y = new y_axis();
$y->set_range(0, 100, 10);
$x = new x_axis();
$x_labels = new x_axis_labels();
$x_labels->set_labels($array_create_date);
$x_labels->set_steps(2);
$x_labels->rotate(40);
$x->set_labels($x_labels);
//There is a bug on the tooltip of bar: can not show #x_label#. So use bar_stack instead of bar here.
// $bar = new bar_filled( '#E2D66A', '#577261' );
// $bar->set_values($array_data);
// $bar->set_tooltip('#x_label#: #val#');
$bar = new bar_stack();
$bar->set_colours(array('#E2D66A', '#577261'));
foreach ($array_data as $date) {
$bar->append_stack(array((int) $date));
}
$bar->set_tooltip('#x_label#: #val#');
$this->view->chart3 = new open_flash_chart();
$this->view->chart3->set_title($title);
$this->view->chart3->add_element($bar);
$this->view->chart3->set_bg_colour('#FFFFFF');
$this->view->chart3->set_x_axis($x);
$this->view->chart3->set_y_axis($y);
// echo $this->view->chart3->toPrettyString();
}
示例12: x_axis
$maximum = $maxima[0];
//-----/end get ranges -----------------
// Prepare the x-axis
$x = new x_axis();
$x->set_range($lowest, $highest);
// Calculate the steps and visible steps
$step = ($highest - $lowest) / 60;
$step_vis = 2;
// do not allow steps to be less than 30 minutes
if ($step < 26400) {
# 86400
$step = 26400;
$step_vis = 1;
}
$x->set_steps($step);
$labels = new x_axis_labels();
$labels->text('#date:Y-m-d#');
$labels->set_steps($step);
$labels->visible_steps($step_vis);
$labels->rotate(90);
$x->set_labels($labels);
// Prepare the y-axis
$y = new y_axis();
// $maximum is already set above
// set the range and y-step
$y->set_range(0, $maximum + getIdealYSteps($maximum));
$y->set_steps(getIdealYSteps($maximum));
# $chart->add_element( $s );
$chart->set_x_axis($x);
$chart->add_y_axis($y);
// echo a pretty ofc-string anyway
示例13: while
while ($val = mssql_fetch_assoc($result)) {
$kecamatan[] = $val['Kecamatan'];
$jumlah[] = $val['Jumlah'];
$total = $val['total'];
$tempJumlah = $val['Jumlah'];
$maxJumlah = $maxJumlah > $tempJumlah ? $maxJumlah : $tempJumlah;
}
}
$max = 0;
$title = new title('Jumlah Data Peserta KB Per Kecamatan, Total : ' . $total . ' ( ' . date("D M d Y") . ' ) ');
$title->set_style('{font-size:20px; color: #bcd6ff; margin:0px; background-color: #5E83BF;}');
$bar = new bar_3d();
$bar->set_values($jumlah);
$bar->colour = '#9999FF';
$bar->set_on_show(new bar_on_show('grow-up', 1, 0));
$labels = new x_axis_labels();
$labels->set_labels($kecamatan);
$y_base = new y_axis_base();
$y_base->set_range(0, $maxJumlah + round($maxJumlah / 2), round($maxJumlah / 10));
$x = new x_axis();
$x->set_labels($labels);
$x->set_3d(5);
$y = new y_axis();
$y->set_labels($y_labels);
$tags = new ofc_tags();
$tags->font('Verdana', 10)->colour('#000000')->align_x_center()->text('#y#');
$i = 0;
foreach ($jumlah as $j) {
$tags->append_tag(new ofc_tag($i, $j));
$i++;
}
示例14: foreach
foreach (array_keys($requests) as $s) {
if ($max_rec < intval($requests[$s])) {
$max_rec = intval($requests[$s]);
}
$request[] = intval($requests[$s]);
}
$chart = new open_flash_chart();
$title = new title('Weekly Requests');
$title->set_style("{font-size: 20px; color: #A2ACBA; text-align: center;}");
$chart->set_title($title);
$chart->set_bg_colour('#FFFFFF');
$area = new area();
$area->set_colour('#5B56B6');
$area->set_values($request);
$chart->add_element($area);
$x_labels = new x_axis_labels();
$x_labels->set_vertical();
$x_labels->set_colour('#A2ACBA');
$x_labels->set_labels($week);
$x = new x_axis();
$x->set_colour('#A2ACBA');
$x->set_grid_colour('#D7E4A3');
$x->set_offset(false);
$x->set_steps(4);
$x->set_labels($x_labels);
$chart->set_x_axis($x);
$x_legend = new x_legend(date("D M d Y"));
$x_legend->set_style('{font-size: 20px; color: #778877}');
$chart->set_x_legend($x_legend);
//
// remove this when the Y Axis is smarter
示例15: y_axis
}
}
if (empty($array)) $array[] = 0;
$bar->set_values( $array );
$bar->set_tooltip("#val#<br>Average = ".commify($avg[0]));
$bar2->set_values( ($avg) );
$bar2->set_colour( "#40FF40" );
$bar2->set_tooltip("#val#<br>Average [#x_label#]");
//
// create a Y Axis object
//
$y = new y_axis();
// grid steps:
$y->set_range( 0, max($array), round(max($array)/10));
$chart->set_y_axis( $y );
$x_labels = new x_axis_labels();
$x_labels->set_vertical();
$x_labels->set_labels( $hms );
$x = new x_axis();
$x->set_labels( $x_labels );
$chart->set_x_axis( $x );
echo $chart->toPrettyString();
break;
case "chart_mpd":
$title = new title( date("D M d Y") );
$bar = new bar_rounded_glass();
// -------------------------
// Get Messages Per Day
// -------------------------
$array = array();