public function create() { $legend = $this->getArg('legend'); $y = $this->getArg('y'); if ($y === NULL) { awImage::drawError("Class LightLinePattern: Argument 'y' must not be NULL."); } $plot = new LinePlot($y); $plot->setSize(0.7, 1); $plot->setCenter(0.35, 0.5); $plot->setPadding(35, 15, 35, 30); $plot->setColor(new Orange()); $plot->setFillColor(new LightOrange(80)); $plot->grid->setType(Line::DASHED); $plot->mark->setType(Mark::CIRCLE); $plot->mark->setFill(new MidRed()); $plot->mark->setSize(6); $plot->legend->setPosition(1, 0.5); $plot->legend->setAlign(Legend::LEFT); $plot->legend->shadow->smooth(TRUE); if ($legend !== NULL) { $plot->legend->add($plot, $legend, Legend::MARK); } return $plot; }
/* * This work is hereby released into the Public Domain. * To view a copy of the public domain dedication, * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. * */ require_once "../../LinePlot.class.php"; $graph = new Graph(300, 200); $graph->setAntiAliasing(TRUE); $x = array(-4, -5, -2, -8, -3, 1, 4, 9, 5, 6, 2); $plot = new LinePlot($x); $plot->setStyle(LINE_DASHED); $plot->setSpace(4, 4, 10, 0); $plot->setPadding(25, 15, 10, 18); $plot->setBackgroundGradient(new LinearGradient(new Color(230, 230, 230), new Color(255, 255, 255), 90)); $plot->setFilledArea(7, 9, new Red(25)); $plot->setFilledArea(1, 4, new Yellow(25)); $plot->setColor(new Color(0, 0, 150, 20)); $plot->grid->setColor(new VeryLightGray()); $plot->mark->setType(MARK_SQUARE); $plot->mark->setSize(4); $plot->mark->setFill(new VeryDarkGreen(30)); $plot->mark->border->show(); $plot->mark->border->setColor(new DarkBlue(60)); $plot->xAxis->label->hide(TRUE); $plot->xAxis->setNumberByTick('minor', 'major', 3); $plot->yAxis->setLabelNumber(8); $plot->legend->add($plot, "My line"); $plot->legend->setPosition(0.9, 0.77);
<?php /* * This work is hereby released into the Public Domain. * To view a copy of the public domain dedication, * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. * */ require_once "../../LinePlot.class.php"; $graph = new Graph(150, 100); $graph->setAntiAliasing(TRUE); $x = array(1, 2, 5, 0.5, 3, 8, 7, 6, 2, -4); $plot = new LinePlot($x); $plot->grid->setNobackground(); $plot->setPadding(20, 8, 8, 20); $plot->setXAxisZero(FALSE); // Set a background gradient $plot->setBackgroundGradient(new LinearGradient(new Color(210, 210, 210), new Color(255, 255, 255), 0)); // Set semi-transparent background gradient $plot->setFillGradient(new LinearGradient(new Color(230, 150, 150, 20), new Color(230, 230, 180, 50), 90)); $plot->xAxis->label->hideFirst(TRUE); $plot->xAxis->label->hideLast(TRUE); $plot->xAxis->setNumberByTick('minor', 'major', 2); $graph->add($plot); $graph->draw();
/** * Формирование графика. * * Функция формирует, а затем записывает в файл ($File) изображение графика по * переданным пользователем данным($Lines). Данная функция может рисовать как одиночные, * так и многолинейные графики.Исходными данными является массив, элементы которого также * является массивами исходных данных для соответствующих графиков (данная структура * сохраняется и для одиночных графиков!). Цвет каждой линии передается в массиве * $Colors, ключи которого совпадают с ключами массива исходных данных. Цвет задается * шестнадцатиричным кодом цвета (например, 0x000000 для черного цвета). * * @param string <заголовок диаграммы> * @param string <полный путь с именем файла-результата> * @param array <исходные данные> * @param array <подписи к оси Ox> * @param array <цвета линий> */ function Artichow_Line($Name, $File, $Lines, $Labels, $Colors) { #----------------------------------------------------------------------------- $Graph = new Graph(1000, 300); $Graph->setDriver('gd'); $Graph->setAntiAliasing(TRUE); #----------------------------------------------------------------------------- $Graph->title->set($Name); $Graph->title->setFont(new Tuffy(15)); $Graph->title->move(0, -5); #----------------------------------------------------------------------------- if (Count($Lines) > 1) { #--------------------------------------------------------------------------- $Group = new PlotGroup(); $Group->setPadding(40, 40); $Group->setBackgroundColor(new Color(240, 240, 240)); } #----------------------------------------------------------------------------- $IsSetLabel = FALSE; #----------------------------------------------------------------------------- foreach ($Lines as $LineID => $Line) { #--------------------------------------------------------------------------- $Plot = new LinePlot($Line); $Color = Color_RGB_Explode($Colors[$LineID]); $Plot->setColor(new Color($Color['R'], $Color['G'], $Color['B'])); $Plot->setThickness(1); $Plot->setBackgroundGradient(new LinearGradient(new Color(240, 240, 240), new Color(255, 255, 255), 0)); $Plot->setFillGradient(new LinearGradient(new LightOrange(10), new VeryLightOrange(90), 90)); $Plot->setPadding(50, 50, 50, 50); #--------------------------------------------------------------------------- $Plot->mark->setType(Mark::CIRCLE); $Plot->mark->setSize(5); #--------------------------------------------------------------------------- $Plot->label->set($Line); $Plot->label->move(0, -15); $Plot->label->setBackgroundGradient(new LinearGradient(new Color(250, 250, 250, 10), new Color(255, 200, 200, 30), 0)); $Plot->label->border->setColor(new Color(20, 20, 20, 20)); $Plot->label->setPadding(2, 2, 2, 2); #--------------------------------------------------------------------------- if (Count($Lines) < 2) { #------------------------------------------------------------------------- $Plot->xAxis->setLabelText($Labels); $Plot->yAxis->setLabelPrecision(1); } else { #------------------------------------------------------------------------- if (!$IsSetLabel) { #----------------------------------------------------------------------- $Plot->setXAxis(Plot::BOTTOM); $IsSetLabel = TRUE; } } #--------------------------------------------------------------------------- if (Count($Lines) > 1) { $Group->add($Plot); } #--------------------------------------------------------------------------- if (Count($Lines) > 1) { #------------------------------------------------------------------------- $Graph->add($Group); #------------------------------------------------------------------------- $Group->axis->bottom->setTickStyle(0); $Group->axis->bottom->setLabelText($Labels); } else { $Graph->add($Plot); } } #----------------------------------------------------------------------------- $Graph->draw($File); #----------------------------------------------------------------------------- return TRUE; }
$plot->label->move(5, -7); if (!empty($_REQUEST["xtitle"]) or !empty($_REQUEST["ytitle"])) { $group->setPadding(35, 15, 27, 27); if (!empty($_REQUEST["xtitle"])) { $group->axis->bottom->title->set($_REQUEST["xtitle"]); } if (!empty($_REQUEST["ytitle"])) { $group->axis->left->title->set($_REQUEST["ytitle"]); } $group->axis->bottom->title->move(4, -6); $group->axis->bottom->setTitleAlignment(LABEL_RIGHT); $group->axis->left->title->move(-2, -4); $group->axis->left->setTitleAlignment(LABEL_TOP); } $plot->setSpace(4, 4, 10, 0); $plot->setPadding(40, 15, 10, 40); $plot->yAxis->title->move(-4, 0); $plot->yAxis->setTitleAlignment(LABEL_TOP); $group->add($plot); $group->axis->bottom->setLabelText($keys_new); $group->axis->bottom->hideTicks(TRUE); if (count($data2) > 0) { if ($type == "linesteps") { list($data_new, $data_label, $keys_new) = build_line_steps($width, $data2, $keys); } else { $data_new = $data2; $data_label = $data2; } $plot = new LinePlot($data_new); $plot->label->set($data_label); $plot->label->move(5, -7);
/* * This work is hereby released into the Public Domain. * To view a copy of the public domain dedication, * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. * */ require_once "../../LinePlot.class.php"; $graph = new Graph(150, 100); $x = array(); for ($i = 0; $i < 8; $i++) { $x[] = cos($i / 3 * M_PI) + mt_rand(-10, 10) / 40; } $plot = new LinePlot($x); $plot->setPadding(22, 5, 25, 8); // Hide grid $plot->grid->setType(LINE_DASHED); // Change background color $plot->setBackgroundColor(new Color(240, 240, 240, 50)); // Set Y on both left and rights sides $plot->setYAxis(PLOT_BOTH); // Change line properties $plot->setColor(new Color(0, 0, 0)); $plot->setFillColor(new Color(240, 190, 130, 50)); // Chenge ticks and labels interval $plot->xAxis->setTickInterval(2); $plot->xAxis->label->hide(TRUE); $plot->xAxis->setNumberByTick('minor', 'major', 1); // Hide first and last values on X axis $plot->xAxis->label->hideFirst(TRUE);
<?php /* * This work is hereby released into the Public Domain. * To view a copy of the public domain dedication, * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. * */ require_once "../../LinePlot.class.php"; $graph = new Graph(150, 100); $graph->setAntiAliasing(TRUE); $x = array(); for ($i = 0; $i < 10; $i++) { $x[] = mt_rand(1, 99) / 10; } $plot = new LinePlot($x); $plot->setBackgroundColor(new Color(240, 240, 240)); $plot->setPadding(30, 8, 8, 20); $plot->setColor(new Color(60, 60, 150)); $plot->setFillGradient(new LinearGradient(new Color(120, 175, 80, 47), new Color(231, 172, 113, 30), 0)); $plot->grid->setType(LINE_DASHED); $plot->yAxis->setLabelNumber(2); $plot->yAxis->setLabelPrecision(1); $plot->xAxis->setLabelInterval(2); $plot->xAxis->setNumberByTick('minor', 'major', 2); $graph->add($plot); $graph->draw();
<?php /* * This work is hereby released into the Public Domain. * To view a copy of the public domain dedication, * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. * */ require_once "../../LinePlot.class.php"; $graph = new Graph(150, 100); $graph->setAntiAliasing(TRUE); $x = array(1, 2, 5, 4, 2, 3); $plot = new LinePlot($x); // Change component padding $plot->setPadding(10, 12, 12, 7); // Set a background gradient $plot->setBackgroundGradient(new LinearGradient(new Color(230, 230, 230), new Color(255, 255, 255), 0)); // Change line background color $plot->setFillGradient(new LinearGradient(new Color(200, 240, 215, 30), new Color(150, 190, 165, 30), 0)); // Hide grid $plot->grid->hide(TRUE); $plot->grid->setNobackground(); $plot->yAxis->label->hide(TRUE); $plot->xAxis->label->hide(TRUE); $plot->label->set($x); $plot->label->setBackgroundColor(new Color(240, 240, 240, 10)); $plot->label->border->setColor(new Color(255, 0, 0, 15)); $plot->label->setPadding(3, 2, 0, 0); $plot->label->setFont(new Font1()); $graph->add($plot);
// fond du cadre du titre $plot->title->setBackgroundColor(new Color(255, 255, 255, 25)); // bord du cadre du titre $plot->title->border->show(); // espacement du texte dans le cadre du titre $plot->title->setPadding(3, 3, 3, 3); // positionement du cadre titre $plot->title->move(0, 20); // LE GRAPHIQUE // Change la couleur de fond de la grille $plot->grid->setBackgroundColor(new Color(255, 255, 255, 30)); // décalement du 0 et de la fin $plot->setSpace(4, 4, 10, 0); // padding du graphique $plot->setPadding(50, 15, 10, 60); // couleur de dégradé du fond du graphique $plot->setBackgroundGradient( new LinearGradient( new Color(210, 210, 210), new Color(255, 255, 255), 0 ) ); // couleur de la ligne $plot->setColor(new Color(0, 0, 150, 20)); // couleur de dégradé sous la ligne $plot->setFillGradient( new LinearGradient( new Color(150, 150, 210), new Color(245, 245, 245),
require_once "../../LinePlot.class.php"; function color($a = NULL) { if ($a === NULL) { $a = 0; } return new Color(mt_rand(20, 180), mt_rand(20, 180), mt_rand(20, 180), $a); } $graph = new Graph(400, 400); $graph->setTiming(TRUE); $x = array(); for ($i = 0; $i < 10; $i++) { $x[] = mt_rand(-20, 100); } $plot = new LinePlot($x); $plot->setPadding(NULL, 40, NULL, NULL); $plot->setBackgroundColor(color(80)); $plot->setYAxis(PLOT_BOTH); $plot->setColor(color()); if (mt_rand(0, 2) > 0) { $plot->setFillGradient(new LinearGradient(color(40), color(60), mt_rand(0, 1) * 90)); } else { $plot->setFillColor(color(64)); } $plot->yAxis->setLabelNumber(mt_rand(0, 10)); $plot->yAxis->setLabelPrecision(1); $plot->yAxis->title->set("Axis des Y : Quarante-deux"); $plot->xAxis->setTickInterval(2); $plot->xAxis->setLabelInterval(2); $plot->xAxis->label->hideFirst(TRUE); $plot->xAxis->label->hideLast(TRUE);
/* * This work is hereby released into the Public Domain. * To view a copy of the public domain dedication, * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. * */ require_once "../../LinePlot.class.php"; $graph = new Graph(150, 100); $graph->setAntiAliasing(TRUE); $x = array(0, 2, 5, 2, 3, 8); $plot = new LinePlot($x); $plot->setXAxisZero(FALSE); $plot->grid->setNobackground(); $plot->setSpace(6, 6, 10, 10); $plot->setPadding(30, 6, 8, 18); // Set a background gradient $plot->setBackgroundGradient(new LinearGradient(new Color(210, 210, 210), new Color(255, 255, 255), 0)); // Change line color $plot->setColor(new Color(0, 0, 150, 20)); // Set line background gradient $plot->setFillGradient(new LinearGradient(new Color(150, 150, 210), new Color(230, 230, 255), 0)); // Change mark type $plot->mark->setType(MARK_CIRCLE); $plot->mark->border->show(); $plot->mark->setSize(6); $plot->yAxis->setLabelPrecision(1); $plot->yAxis->label->setFont(new Font1()); $plot->xAxis->label->setFont(new Font1()); $graph->add($plot); $graph->draw();
* Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. * */ require_once "../../LinePlot.class.php"; $graph = new Graph(300, 175); $graph->setAntiAliasing(TRUE); $x = array(4, 3, 1, 0, -2, 1, 3, 2, 3, 5, 4, 1); $plot = new LinePlot($x); $plot->setXAxisZero(FALSE); $plot->grid->hide(TRUE); $plot->title->set("Using dashed line and legend"); $plot->title->setFont(new TuffyItalic(9)); $plot->title->setBackgroundColor(new Color(255, 255, 255, 50)); $plot->title->setPadding(3, 3, 3, 3); $plot->title->move(0, 20); $plot->setSpace(6, 6, 10, 10); $plot->setPadding(30, 10, 15, 25); $plot->setBackgroundColor(new Color(245, 245, 245)); $plot->setStyle(LINE_DASHED); $plot->setColor(new Color(0, 150, 0, 20)); $plot->setFillGradient(new LinearGradient(new Color(220, 220, 150, 40), new Color(255, 255, 210, 30), 0)); $graph->shadow->setSize(4); $graph->shadow->setPosition(SHADOW_LEFT_BOTTOM); $graph->shadow->smooth(TRUE); $plot->legend->add($plot, "Apples"); $plot->legend->shadow->setSize(0); $plot->legend->setAlign(LEGEND_CENTER, LEGEND_TOP); $plot->legend->setPosition(0.75, 0.6); $plot->legend->setTextFont(new Tuffy(8)); $graph->add($plot); $graph->draw();
* To view a copy of the public domain dedication, * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. * */ require_once "../LinePlot.class.php"; $graph = new Graph(375, 200); // Set title $graph->title->set('Star marks'); $graph->title->setFont(new Tuffy(12)); $graph->title->setColor(new DarkRed()); $plot = new LinePlot(array(5, 3, 4, 7, 6, 5, 8, 4, 7)); // Change plot size and position $plot->setSize(0.76, 1); $plot->setCenter(0.38, 0.5); $plot->setPadding(30, 15, 38, 25); $plot->setColor(new Orange()); $plot->setFillColor(new LightOrange(80)); // Change grid style $plot->grid->setType(LINE_DASHED); // Add customized marks $plot->mark->setType(MARK_STAR); $plot->mark->setFill(new MidRed()); $plot->mark->setSize(6); // Change legend $plot->legend->setPosition(1, 0.5); $plot->legend->setAlign(LEGEND_LEFT); $plot->legend->shadow->smooth(TRUE); $plot->legend->add($plot, 'My line', LEGEND_MARK); $graph->add($plot); $graph->draw();
<?php /* * This work is hereby released into the Public Domain. * To view a copy of the public domain dedication, * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. * */ require_once "../LinePlot.class.php"; $graph = new Graph(400, 300); $graph->setAntiAliasing(TRUE); $x = array(1, 2, 5, 0.5, 3, 8, 7, 6, 2, -4); $plot = new LinePlot($x); // Change component padding $plot->setPadding(10, NULL, NULL, NULL); // Change component space $plot->setSpace(5, 5, 5, 5); // Set a background color $plot->setBackgroundColor(new Color(230, 230, 230)); // Change grid background color $plot->grid->setBackgroundColor(new Color(235, 235, 180, 60)); // Hide grid $plot->grid->hide(TRUE); // Hide labels on Y axis $plot->yAxis->label->hide(TRUE); $plot->xAxis->label->setInterval(2); $plot->label->set($x); $plot->label->setFormat('%.1f'); $plot->label->setBackgroundColor(new Color(240, 240, 240, 15)); $plot->label->border->setColor(new Color(255, 0, 0, 15));
<?php /* * This work is hereby released into the Public Domain. * To view a copy of the public domain dedication, * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. * */ require_once "../../LinePlot.class.php"; $graph = new Graph(500, 100); $graph->setAntiAliasing(TRUE); $graph->border->hide(); $x = array(); for ($i = 0; $i < 20; $i++) { $x[] = mt_rand(4, 12); } $plot = new LinePlot($x); $plot->setSpace(0, 0, 50, 0); $plot->setPadding(3, 3, 3, 3); $plot->setBackgroundGradient(new LinearGradient(new Color(230, 230, 230), new Color(255, 255, 255), 0)); $plot->setColor(new Color(0, 0, 180, 20)); $plot->setFillGradient(new LinearGradient(new Color(220, 220, 230, 25), new Color(240, 240, 255, 25), 90)); $plot->xAxis->hide(TRUE); $plot->yAxis->hide(TRUE); $graph->add($plot); $graph->draw();
function CreeGraphClassementZoom($fichier) { // Initialement, ces variables étaient passés dans la session // $G_listeJeux=$_SESSION['G_listeJeuxZoom']; // $G_listeJoueurs=$_SESSION['G_listeJoueursZoom']; // $G_listeResultats=$_SESSION['G_listeResultatsZoom']; // $G_MesCouleurs=$_SESSION['G_mesCouleurs']; global $G_ListeJeuxZoom; global $G_MesCouleurs; global $G_ListeResultatsMoyensZoom; global $G_ListeJoueurs; // Le niveau de transparence est définit à 95% // Ici, le graphique mesurera 620 x 700 pixels. $graph = new Graph(620, 700); // L'anti-aliasing permet d'afficher des courbes plus naturelles, // mais cette option consomme beaucoup de ressources sur le serveur. $graph->setAntiAliasing(TRUE); // Titre du graphe ! $graph->title->set("Zoom sur les quatre dernières moyennes"); // L'objet group permet de gérer plusieurs courbes sur un même grpahiques $group = new PlotGroup(); // Le style des lignes des courbes est dashed $group->grid->setType(LINE_DASHED); // La marge gauche est fixée à 40px du bord, droite à 20, haut à 40px et basse à 120px $group->setPadding(40, 20, 40, 120); // Le titre sur les absisses est : % Réussite $group->axis->left->title->set("% Reussite"); $group->setYAxisZero(false); // Les libellés sur les absisses sont inclinés de 45% $group->axis->bottom->label->setAngle(45); // Affiche 10 marques entre 2 marques majeures $group->axis->left->setNumberByTick('minor', 'major', 10); // Titre des ordonnées //$group->axis->bottom->title->set("Journées"); // La légende est affiché en bas du graphe $group->legend->setModel(LEGEND_MODEL_BOTTOM); // Position de la légénde par rapport au graphe $group->legend->setPosition(NULL, 0.9); // Nb de colonnes $group->legend->setRows(2); //$group->legend->shadow->hide(); // On créé autant de courbes qu'il y a de joueurs ! for ($j = 0; $j < sizeof($G_ListeJoueurs); $j++) { // Recherche des résultats du joueur $j $G_ResultatJoueur = array(); for ($k = 0; $k < sizeof($G_ListeJeuxZoom); $k++) { if (isset($G_ListeResultatsMoyensZoom[$k][$j])) { $G_ResultatJoueur[$k] = $G_ListeResultatsMoyensZoom[$k][$j]; } else { $G_ResultatJoueur[$k] = null; } } // Création d'une courbe pour ce joueur $plot = new LinePlot($G_ResultatJoueur); $plot->setColor(new Color($G_MesCouleurs[$j][0], $G_MesCouleurs[$j][1], $G_MesCouleurs[$j][2])); $plot->setFillColor(new Color($G_MesCouleurs[$j][0], $G_MesCouleurs[$j][1], $G_MesCouleurs[$j][2], NIVEAU_TRANSPARENCE)); $plot->mark->setType(MARK_CIRCLE); if ($j % 3 == 0) { $plot->mark->setType(MARK_TRIANGLE); } if ($j % 4 == 0) { $plot->mark->setType(MARK_CROSS); } $plot->mark->setFill(new Color($G_MesCouleurs[$j][0], $G_MesCouleurs[$j][1], $G_MesCouleurs[$j][2])); $plot->mark->setSize(7); $plot->yAxis->setLabelNumber(0.5); // $plot->xAxis->label->setAngle(45); $plot->setPadding(10, 10, 10, 10); // Ajoute d'une légende pour cette courbe et ce joueur $group->legend->add($plot, $G_ListeJoueurs[$j], LEGEND_MARK); // Ajoute cette courbe au group $group->add($plot); } // Fonction qui retourne les Abscisses function setAbscisseZoom($value) { global $G_ListeJeuxZoom; return $G_ListeJeuxZoom[$value]; } $group->axis->bottom->label->setCallbackFunction('setAbscisseZoom'); // Fonction qui retourne les Ordonnés function setOrdonneZoom($value) { return round($value); } $group->axis->left->label->setCallbackFunction('setOrdonneZoom'); // Ajout de ce groupe au graphique $graph->add($group); $graph->draw($fichier); }
* Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. * */ require_once "../../LinePlot.class.php"; $graph = new Graph(280, 200); $x = array(); for ($i = 115; $i < 115 + 180; $i++) { $x[] = cos($i / 25); } function format($value) { return sprintf("%.1f", $value) . ' %'; } $plot = new LinePlot($x); $plot->setBackgroundColor(new Color(240, 240, 240)); $plot->setPadding(40, 15, 15, 15); $plot->setColor(new Color(60, 60, 150)); $plot->setFillColor(new Color(120, 175, 80, 47)); $plot->grid->setType(LINE_DASHED); $plot->yAxis->setLabelNumber(6); $plot->yAxis->setLabelPrecision(1); $plot->yAxis->setNumberByTick('minor', 'major', 1); $plot->yAxis->label->setCallbackFunction('format'); $plot->yAxis->label->setFont(new Tuffy(7)); $plot->xAxis->setNumberByTick('minor', 'major', 3); $plot->xAxis->label->hideFirst(TRUE); $plot->xAxis->setLabelInterval(50); $plot->xAxis->label->setFont(new Tuffy(7)); $plot->grid->setInterval(1, 50); $graph->shadow->setSize(4); $graph->shadow->setPosition(SHADOW_RIGHT_BOTTOM);