Inheritance: extends LineGraph
示例#1
0
 public function createScoreByThemeGraphic($questionnaireId, $userId, $filepath, $verificador = false)
 {
     $graphDefinitions = $this->getScoreByThemeGraphicDefinitions($questionnaireId, $userId, $verificador);
     $graph = new RadarGraph(600, 300);
     $graph->SetColor("white");
     $graph->SetShadow();
     $graph->SetCenter(0.52, 0.55);
     $graph->HideTickMarks();
     $graph->SetTitles($graphDefinitions['ThemeNames']);
     $graph->yscale->SetAutoMax(100);
     $graph->title->Set("Ciclo " . date('Y'));
     $graph->title->SetFont(FF_FONT1, FS_BOLD);
     $graph->axis->SetFont(FF_FONT1, FS_NORMAL);
     $graph->axis->SetWeight(1);
     $graph->axis->SetColor("darkgray");
     $graph->grid->SetLineStyle("dashed");
     $graph->grid->SetColor("darkgray");
     $graph->grid->SetWeight(1);
     $graph->grid->Show();
     $actual = new RadarPlot($graphDefinitions['ThemeScores']);
     $actual->SetColor('darkorchid4', 'bisque');
     $actual->SetLineWeight(4);
     $graph->Add($actual);
     return $graph->Stroke($filepath);
 }
示例#2
0
 public static function Radar($data)
 {
     require_once __DIR__ . '/../include/jpgraph/jpgraph.php';
     require_once __DIR__ . '/../include/jpgraph/jpgraph_radar.php';
     $graph = new RadarGraph(300, 300);
     $graph->SetScale('lin', 0, 50);
     $graph->yscale->ticks->Set(25, 5);
     $graph->SetColor('white');
     $graph->SetCenter(0.5, 0.55);
     $graph->axis->SetFont(FF_FONT1, FS_BOLD);
     $graph->axis->SetWeight(2);
     // Uncomment the following lines to also show grid lines.
     $graph->grid->SetLineStyle('dashed');
     $graph->grid->SetColor('navy@0.5');
     $graph->grid->Show();
     $graph->ShowMinorTickMarks();
     $graph->title->Set('Quality result');
     $graph->title->SetFont(FF_FONT1, FS_BOLD);
     $titles = array();
     $datas = array();
     foreach ($data as $key => $value) {
         $titles[] = $key;
         $datas[] = $value;
     }
     $graph->SetTitles($titles);
     $plot = new RadarPlot($datas);
     //$plot->SetLegend('Goal');
     //$plot->SetColor('red','lightred');
     //$plot->SetFillColor('lightblue');
     $plot->SetLineWeight(2);
     $graph->Add($plot);
     $graph->Stroke();
 }
示例#3
0
<?php

// content="text/plain; charset=utf-8"
require_once 'jpgraph/jpgraph.php';
require_once 'jpgraph/jpgraph_log.php';
require_once 'jpgraph/jpgraph_radar.php';
// Some data to plot
$data = array(242, 58, 1500, 12, 1397, 810, 373);
$data2 = array(447, 176, 1472, 191, 1616, 42, 46);
// Create the graph
$graph = new RadarGraph(300, 350);
// Use logarithmic scale (If you don't use any SetScale()
// the radar graph will default to linear scale
$graph->SetScale('log');
$graph->title->SetFont(FF_ARIAL, FS_BOLD, 16);
$graph->title->Set('Logarithmic scale');
$graph->title->SetMargin(10);
// Make the radar graph fill out it's bounding box
$graph->SetPlotSize(0.8);
$graph->SetCenter(0.5, 0.55);
// Note: Enabling this results in a very noticable slow
// down of the image generation! And more load on your
// server.
$graph->img->SetAntiAliasing();
// Uncomment the following line if you want to supress
// minor tick marks
//$graph->yscale->ticks->SupressMinorTickMarks();
// We want the major tick marks to be black and minor
// slightly less noticable
$graph->yscale->ticks->SetMarkColor('black', 'darkgray');
// Set the axis title font
示例#4
0
<?php

// $Id$
include "../jpgraph.php";
include "../jpgraph_radar.php";
$graph = new RadarGraph(300, 300, 'auto');
$graph->SetScale("lin", 0, 50);
$graph->yscale->ticks->Set(25, 5);
$graph->SetColor("white");
$graph->SetShadow();
$graph->SetCenter(0.5, 0.55);
$graph->axis->SetFont(FF_FONT1, FS_BOLD);
$graph->axis->SetWeight(2);
// Uncomment the following lines to also show grid lines.
//$graph->grid->SetLineStyle("longdashed");
//$graph->grid->SetColor("navy");
//$graph->grid->Show();
$graph->ShowMinorTickMarks();
$graph->title->Set("Quality result");
$graph->title->SetFont(FF_FONT1, FS_BOLD);
$graph->SetTitles(array("One", "Two", "Three", "Four", "Five", "Sex", "Seven", "Eight", "Nine", "Ten"));
$plot = new RadarPlot(array(12, 35, 20, 30, 33, 15, 37));
$plot->SetLegend("Goal");
$plot->SetColor("red", "lightred");
$plot->SetFillColor('lightblue');
$plot->SetLineWeight(2);
$graph->Add($plot);
$graph->Stroke();
示例#5
0
<?php

include "../jpgraph.php";
include "../jpgraph_radar.php";
// Some data to plot
$data = array(55, 80, 46, 71, 95);
// Create the graph and the plot
$graph = new RadarGraph(300, 200, "auto");
$graph->title->Set('Weekly goals');
$graph->subtitle->Set('Year 2003');
$plot = new RadarPlot($data);
$plot->SetFillColor('lightred');
$graph->SetSize(0.6);
$graph->SetPos(0.5, 0.6);
// Add the plot and display the graph
$graph->Add($plot);
$graph->Stroke();
 /**
  * 
  * Utiliza lib jpgraph
  * 
  * @param type $arrCriteria
  * @param type $arrRadarData
  * @param type $arrTabulation
  * @param type $arrPunctuation
  * @param type $dirName
  * @return boolean|string
  */
 public function makeRadarPlot($arrCriteria, $arrRadarData, $arrTabulation, $arrPunctuation, $dirName)
 {
     // content="text/plain; charset=utf-8"
     require_once APPLICATION_PATH_LIBS . '/jpgraph/src/jpgraph.php';
     require_once APPLICATION_PATH_LIBS . '/jpgraph/src/jpgraph_radar.php';
     $criterios = array();
     foreach ($arrCriteria as $chave => $valor) {
         $criterios[$chave] = utf8_decode(" " . $chave . " - " . $valor);
     }
     if (!is_array($arrRadarData)) {
         return false;
     }
     $titles = array_values($criterios);
     $data = array_values($arrRadarData);
     $graph = new RadarGraph(635, 355);
     $graph->SetShadow();
     $graph->SetScale('lin', $aYMin = 0, $aYMax = 100);
     $graph->yscale->ticks->Set(50, 10);
     $graph->title->Set("Porcentagem de acertos por Critério");
     $graph->title->SetFont(FF_VERDANA, FS_NORMAL, 12);
     //$graph->subtitle->Set("Pontuação por Critério em %");
     //$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
     $graph->SetTitles($titles);
     $graph->SetCenter(0.5, 0.54);
     //$graph->HideTickMarks();
     $graph->ShowMinorTickMArks();
     $graph->SetColor('white');
     $graph->grid->SetLineStyle('dashed');
     $graph->axis->SetColor('darkgray@0.3');
     $graph->grid->SetColor('darkgray@0.3');
     $graph->grid->Show();
     $graph->SetGridDepth(DEPTH_BACK);
     $plot = new RadarPlot($data);
     $plot->SetColor('red@0.2');
     $plot->SetLineWeight(3);
     $plot->SetFillColor('skyblue4@0.7');
     $graph->Add($plot);
     $radarPath = $dirName . "radarTMP.png";
     $graph->Stroke($radarPath);
     return $radarPath;
 }
示例#7
0
<?php

// content="text/plain; charset=utf-8"
require_once 'jpgraph/jpgraph.php';
require_once 'jpgraph/jpgraph_radar.php';
$titles = array("N", '', "NW", '', "W", '', "SW", '', 'S', '', "SE", '', "E", '', "NE", '');
$data = array(0, 0, 8, 10, 70, 90, 42, 0, 70, 60, 50, 40, 30, 40, 37.8, 72);
$graph = new RadarGraph(250, 270);
$graph->title->Set("Accumulated PPM");
$graph->title->SetFont(FF_VERDANA, FS_NORMAL, 12);
$graph->subtitle->Set("(according to direction)");
$graph->subtitle->SetFont(FF_VERDANA, FS_ITALIC, 10);
$graph->SetTitles($titles);
$graph->SetCenter(0.5, 0.55);
$graph->HideTickMarks();
$graph->SetColor('lightyellow');
$graph->axis->SetColor('darkgray@0.3');
$graph->grid->SetColor('darkgray@0.3');
$graph->grid->Show();
$graph->SetGridDepth(DEPTH_BACK);
$plot = new RadarPlot($data);
$plot->SetColor('red@0.2');
$plot->SetLineWeight(1);
$plot->SetFillColor('red@0.7');
$graph->Add($plot);
$graph->Stroke();
示例#8
0
<?php

// content="text/plain; charset=utf-8"
require_once 'jpgraph/jpgraph.php';
require_once 'jpgraph/jpgraph_radar.php';
// Some data to plot
$data = array(55, 80, 26, 31, 95);
// Create the graph and the plot
$graph = new RadarGraph(250, 200);
// Add a drop shadow to the graph
$graph->SetShadow();
// Create the titles for the axis
$titles = $gDateLocale->GetShortMonth();
$graph->SetTitles($titles);
$graph->SetColor('lightyellow');
// ADjust the position to make more room
// for the legend
$graph->SetCenter(0.45, 0.5);
// Add grid lines
$graph->grid->Show();
$graph->grid->SetColor('darkred');
$graph->grid->SetLineStyle('dashed');
$plot = new RadarPlot($data);
$plot->SetFillColor('lightblue');
$plot->SetLegend("QA results");
// Add the plot and display the graph
$graph->Add($plot);
$graph->Stroke();
示例#9
0
<?php

include "../jpgraph.php";
include "../jpgraph_radar.php";
$titles = array('Planning', 'Quality', 'Time', 'RR', 'CR', 'DR');
$data = array(18, 40, 70, 90, 42, 66);
$graph = new RadarGraph(300, 280, "auto");
$graph->title->Set("Radar with marks");
$graph->title->SetFont(FF_VERDANA, FS_NORMAL, 12);
$graph->SetTitles($titles);
$graph->SetCenter(0.5, 0.55);
$graph->HideTickMarks();
$graph->SetColor('lightgreen@0.7');
$graph->axis->SetColor('darkgray');
$graph->grid->SetColor('darkgray');
$graph->grid->Show();
$graph->axis->title->SetFont(FF_ARIAL, FS_NORMAL, 12);
$graph->axis->title->SetMargin(5);
$graph->SetGridDepth(DEPTH_BACK);
$graph->SetSize(0.6);
$plot = new RadarPlot($data);
$plot->SetColor('red@0.2');
$plot->SetLineWeight(1);
$plot->SetFillColor('red@0.7');
$plot->mark->SetType(MARK_IMG_SBALL, 'red');
$graph->Add($plot);
$graph->Stroke();
示例#10
0
 public function radarGraph_3(&$data, &$data_pro, $project_id)
 {
     require_once '../app/classes/jpgraph/jpgraph_radar.php';
     require_once '../app/classes/jpgraph/jpgraph_iconplot.php';
     //数组处理
     $title_array = array();
     $sys_array = array();
     $pro_array = array();
     foreach ($data['advantage']['value'] as $value) {
         $data_pro_tmp = $data_pro;
         $title_array[] = $value['chs_name'];
         $sys_array[] = $value['score'];
         $data_pro_tmp = array_flip($data_pro_tmp);
         $key = $data_pro_tmp[trim($value['chs_name'])];
         $pro_array[] = $data_pro[$key + 1];
     }
     foreach ($data['disadvantage']['value'] as $value) {
         $data_pro_tmp = $data_pro;
         $title_array[] = $value['chs_name'];
         $sys_array[] = $value['score'];
         $data_pro_tmp = array_flip($data_pro_tmp);
         $key = $data_pro_tmp[trim($value['chs_name'])];
         $pro_array[] = $data_pro[$key + 1];
     }
     // Create the basic rtadar graph
     $graph = new RadarGraph(600, 450);
     // Set background color and shadow
     $graph->SetColor("white");
     // 		$graph->SetShadow();
     // Position the graph
     $graph->SetCenter(0.45, 0.5);
     $graph->SetTitles($title_array);
     // Setup the axis formatting
     $graph->axis->title->SetFont(FF_CHINESE, FS_NORMAL, 11);
     $graph->axis->SetFont(FF_FONT1, FS_BOLD, 11);
     $graph->axis->SetWeight(1);
     // Setup the grid lines
     $graph->grid->SetLineStyle("solid");
     $graph->grid->SetColor("gray");
     $graph->grid->Show();
     $graph->SetGridDepth(DEPTH_BACK);
     $graph->SetSize(0.6);
     $graph->HideTickMarks();
     // Setup graph titles
     // Create the first radar plot
     $plot = new RadarPlot($pro_array);
     $plot->SetLegend("胜任标准");
     $plot->SetColor("blue", "lightblue");
     $plot->SetFill(false);
     $plot->SetLineWeight(3);
     // Create the second radar plot
     $plot2 = new RadarPlot($sys_array);
     $plot2->SetLegend("个人测评值");
     $plot2->SetColor("red", "lightred");
     $plot2->mark->SetType(MARK_IMG_SBALL, 'red');
     $plot2->SetFill(false);
     $plot2->SetLineWeight(3);
     // Add the plots to the graph
     $graph->Add($plot);
     $graph->Add($plot2);
     $date = date('H_i_s');
     $stamp = rand(100, 900);
     $fileName = './tmp/' . $project_id . $date . '_' . $stamp . '.jpeg';
     $graph->Stroke($fileName);
     return $fileName;
 }
示例#11
0
 /**
  * 
  * 
  * @param type $arrCriteria
  * @param type $arrRadarData
  * @param type $arrTabulation
  * @param type $arrPunctuation
  * @param type $dirName
  * @return boolean|string
  */
 public function makeRadarPlot($arrCriteria, $arrRadarData, $arrTabulation, $arrPunctuation, $dirName, $strCiclo)
 {
     //        var_dump('arrCriteria: ',$arrCriteria);
     //        echo "<br><br>";
     //var_dump('arrRadarData: ',$arrRadarData);
     //echo "<br><br>";
     //        var_dump('arrTabulation: ',$arrTabulation);
     //        echo "<br><br>";
     //        var_dump('arrPunctuation: ',$arrPunctuation);
     //
     //        //exit;
     // content="text/plain; charset=utf-8"
     require_once APPLICATION_PATH_LIBS . '/jpgraph/src/jpgraph.php';
     require_once APPLICATION_PATH_LIBS . '/jpgraph/src/jpgraph_radar.php';
     $criterios = array();
     $criterios[1] = utf8_decode($arrCriteria[1]);
     $criterios[8] = utf8_decode($arrCriteria[8]);
     $criterios[7] = utf8_decode($arrCriteria[7]);
     $criterios[6] = utf8_decode($arrCriteria[6]);
     $criterios[5] = utf8_decode($arrCriteria[5]);
     $criterios[4] = utf8_decode($arrCriteria[4]);
     $criterios[3] = utf8_decode($arrCriteria[3]);
     $criterios[2] = utf8_decode($arrCriteria[2]);
     //var_dump('criterios: ', $criterios);
     //echo "<br><br>";
     if (!is_array($arrRadarData)) {
         return false;
     }
     //mudanca de ultima hora para alterar o sentido no print do radar na devolutiva.
     //nao ha um metodo na lib jpgraph que altere o sentido de rotacao ao printar o grafico radar.
     $arrRadarDataMartelada = array();
     $arrRadarDataMartelada[1] = $arrRadarData[1];
     $arrRadarDataMartelada[8] = $arrRadarData[8];
     $arrRadarDataMartelada[7] = $arrRadarData[7];
     $arrRadarDataMartelada[6] = $arrRadarData[6];
     $arrRadarDataMartelada[5] = $arrRadarData[5];
     $arrRadarDataMartelada[4] = $arrRadarData[4];
     $arrRadarDataMartelada[3] = $arrRadarData[3];
     $arrRadarDataMartelada[2] = $arrRadarData[2];
     $titles = array_values($criterios);
     //$data = array_values($arrRadarData);
     //implementa martelada
     $data = array_values($arrRadarDataMartelada);
     //var_dump('arrRadarDataMartelada', $arrRadarDataMartelada);
     //echo "<br><br>";
     //var_dump('data', $data);
     $this->setArrCriteria($arrCriteria);
     $this->setArrPunctuation($arrPunctuation);
     $this->setArrRadarData($arrRadarData);
     $this->setArrTabulation($arrTabulation);
     $graph = new RadarGraph(635, 355);
     $graph->SetShadow();
     $graph->SetScale('lin', $aYMin = 0, $aYMax = 100);
     $graph->yscale->ticks->Set(50, 10);
     //$graph->title->Set("Porcentagem de acertos por Critério");
     $programaTipo = Zend_Registry::get('programaTipo');
     $strCiclo = $programaTipo != 'MpeBrasil' ? '' : ' Ciclo ' . $strCiclo;
     $tituloCiclo = "Desempenho da Empresa" . $strCiclo;
     $graph->title->Set($tituloCiclo);
     $graph->title->SetFont(FF_VERDANA, FS_NORMAL, 12);
     //$graph->subtitle->Set("Pontuação por Critério em %");
     //$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
     $graph->SetTitles($titles);
     $graph->SetCenter(0.5, 0.54);
     //$graph->HideTickMarks();
     $graph->ShowMinorTickMArks();
     $graph->SetColor('white');
     $graph->grid->SetLineStyle('dashed');
     $graph->axis->SetColor('darkgray@0.3');
     $graph->grid->SetColor('darkgray@0.3');
     $graph->grid->Show();
     $graph->SetGridDepth(DEPTH_BACK);
     $plot = new RadarPlot($data);
     $plot->SetColor('red@0.2');
     $plot->SetLineWeight(3);
     $plot->SetFillColor('skyblue4@0.7');
     $graph->Add($plot);
     $radarPath = $dirName . "radarTMP.png";
     $graph->Stroke($radarPath);
     return $radarPath;
 }
<?php

require_once __DIR__ . '/../../include/jpgraph/jpgraph.php';
require_once __DIR__ . '/../../include/jpgraph/jpgraph_radar.php';
$graph = new RadarGraph(300, 250);
$graph->SetScale('lin', 5, 17);
//$graph->yscale->ticks->Set(25,5);
$graph->SetColor('#D5D5BD');
$graph->SetCenter(0.5, 0.5);
$graph->axis->HideTicks();
$graph->axis->HideLAbels();
$graph->axis->SetColor("#3E404F");
$graph->SetFrame(true, '#3E404F', 1);
// Uncomment the following lines to also show grid lines.
$graph->grid->SetLineStyle('dashed');
$graph->grid->SetColor('#3E404F');
$graph->grid->Show();
//$graph->ShowMinorTickMarks();
$titles = array();
$datas = array();
foreach ($_GET as $key => $value) {
    $titles[] = $key;
    $datas[] = $value;
}
$graph->SetTitles($titles);
$plot = new RadarPlot($datas);
//$plot->SetLegend('Goal');
$plot->SetColor('#900000', 'lightred');
$plot->SetFillColor('#E7E7D2');
$plot->SetLineWeight(2);
$graph->Add($plot);
示例#13
0
<?php

// content="text/plain; charset=utf-8"
require_once 'jpgraph/jpgraph.php';
require_once 'jpgraph/jpgraph_radar.php';
$graph = new RadarGraph(300, 300);
$graph->SetScale('lin', 0, 50);
$graph->yscale->ticks->Set(25, 5);
$graph->SetColor('white');
$graph->SetShadow();
$graph->SetCenter(0.5, 0.55);
$graph->axis->SetFont(FF_FONT1, FS_BOLD);
$graph->axis->SetWeight(2);
// Uncomment the following lines to also show grid lines.
$graph->grid->SetLineStyle('dashed');
$graph->grid->SetColor('navy@0.5');
$graph->grid->Show();
$graph->ShowMinorTickMarks();
$graph->title->Set('Quality result');
$graph->title->SetFont(FF_FONT1, FS_BOLD);
$graph->SetTitles(array('One', 'Two', 'Three', 'Four', 'Five', 'Sex', 'Seven', 'Eight', 'Nine', 'Ten'));
$plot = new RadarPlot(array(12, 35, 20, 30, 33, 15, 37));
$plot->SetLegend('Goal');
$plot->SetColor('red', 'lightred');
$plot->SetFillColor('lightblue');
$plot->SetLineWeight(2);
$graph->Add($plot);
$graph->Stroke();
示例#14
0
        }
        $plot->value->HideZero();
        $plot->value->SetFormat('%u');
        $plot->value->SetFont(FF_FONT1, FS_BOLD);
        $plot->value->SetColor('blue');
        $plot->value->SetMargin(10);
        $plot->value->Show();
    }
    // Add the data plot to the graph
    $graph->Add($plot);
} elseif ($options['graph_type'] == 'radar') {
    require_once "{$jpgraph}/jpgraph_radar.php";
    $background = "white";
    $incref = false;
    // Setup graph
    $graph = new RadarGraph($width, 250, "auto");
    //$graph->SetShadow();
    $graph->SetFrame(false);
    $graph->title->Set($data['title']);
    $graph->title->SetFont(FF_FONT1, FS_BOLD);
    $graph->SetMarginColor($background);
    $graph->img->SetMargin(40, 30, 20, 40);
    $graph->SetTitles($data['legend']);
    $graph->SetCenter(0.5, 0.55);
    $graph->HideTickMarks();
    $graph->SetColor($background);
    $graph->grid->SetColor('darkgray');
    $graph->grid->Show();
    $graph->axis->title->SetMargin(5);
    $graph->SetGridDepth(DEPTH_BACK);
    $graph->SetSize(0.6);
示例#15
0
<?php

include "../jpgraph.php";
include "../jpgraph_radar.php";
// Some data to plot
$data = array(55, 80, 46, 71, 95);
// Create the graph and the plot
$graph = new RadarGraph(250, 200, "auto");
$plot = new RadarPlot($data);
// Add the plot and display the graph
$graph->Add($plot);
$graph->Stroke();
示例#16
0
<?php

include "../jpgraph.php";
include "../jpgraph_log.php";
include "../jpgraph_radar.php";
// Some data to plot
$data = array(242, 58, 500, 12, 397, 810, 373);
// Create the graph
$graph = new RadarGraph(200, 200, "auto");
// Uncomment the following line to use anti-aliasing
// Note: Enabling this results in a very noticable slow
// down of the image generation! And more load on your
// server. Use it wisly!!
$graph->img->SetAntiAliasing();
// Make the spider graph fill out it's bounding box
$graph->SetPlotSize(0.85);
// Use logarithmic scale (If you don't use any SetScale()
// the spider graph will default to linear scale
$graph->SetScale("log");
// Uncomment the following line if you want to supress
// minor tick marks
// $graph->yscale->ticks->SupressMinorTickMarks();
// We want the major tick marks to be black and minor
// slightly less noticable
$graph->yscale->ticks->SetMarkColor("black", "darkgray");
// Set the axis title font
$graph->axis->title->SetFont(FF_ARIAL, FS_BOLD, 12);
// Use blue axis
$graph->axis->SetColor("blue");
$plot = new RadarPlot($data);
$plot->SetLineWeight(2);
示例#17
0
<?php

include "../jpgraph.php";
include "../jpgraph_radar.php";
// Create the basic rtadar graph
$graph = new RadarGraph(300, 200, "auto");
// Set background color and shadow
$graph->SetColor("white");
$graph->SetShadow();
// Position the graph
$graph->SetCenter(0.4, 0.55);
// Setup the axis formatting
$graph->axis->SetFont(FF_FONT1, FS_BOLD);
$graph->axis->SetWeight(2);
// Setup the grid lines
$graph->grid->SetLineStyle("longdashed");
$graph->grid->SetColor("navy");
$graph->grid->Show();
$graph->HideTickMarks();
// Setup graph titles
$graph->title->Set("Quality result");
$graph->title->SetFont(FF_FONT1, FS_BOLD);
$graph->SetTitles(array("One", "Two", "Three", "Four", "Five", "Sex", "Seven", "Eight", "Nine", "Ten"));
// Create the first radar plot
$plot = new RadarPlot(array(30, 80, 60, 40, 71, 81, 47));
$plot->SetLegend("Goal");
$plot->SetColor("red", "lightred");
$plot->SetFill(false);
$plot->SetLineWeight(2);
// Create the second radar plot
$plot2 = new RadarPlot(array(70, 40, 30, 80, 31, 51, 14));
示例#18
0
<?php

// content="text/plain; charset=utf-8"
require_once 'jpgraph/jpgraph.php';
require_once 'jpgraph/jpgraph_radar.php';
// Some data to plot
$data = array(55, 80, 46, 71, 95);
// Create the graph and the plot
$graph = new RadarGraph(250, 200);
// Create the titles for the axis
$titles = $gDateLocale->GetShortMonth();
$graph->SetTitles($titles);
$plot = new RadarPlot($data);
$plot->SetFillColor('lightblue');
// Add the plot and display the graph
$graph->Add($plot);
$graph->Stroke();
 /**
  * construct multigraph
  */
 public function Values($values)
 {
     parent::Values($values);
     if (!$this->values->error) {
         $this->multi_graph = new MultiGraph($this->values, $this->force_assoc, $this->datetime_keys, $this->require_integer_keys);
     }
 }
示例#20
0
<?php

// content="text/plain; charset=utf-8"
require_once 'jpgraph/jpgraph.php';
require_once 'jpgraph/jpgraph_radar.php';
// Create the basic radar graph
$graph = new RadarGraph(300, 200);
$graph->img->SetAntiAliasing();
// Set background color and shadow
$graph->SetColor("white");
$graph->SetShadow();
// Position the graph
$graph->SetCenter(0.4, 0.55);
// Setup the axis formatting
$graph->axis->SetFont(FF_FONT1, FS_BOLD);
// Setup the grid lines
$graph->grid->SetLineStyle("solid");
$graph->grid->SetColor("navy");
$graph->grid->Show();
$graph->HideTickMarks();
// Setup graph titles
$graph->title->Set("Quality result");
$graph->title->SetFont(FF_FONT1, FS_BOLD);
$graph->SetTitles($gDateLocale->GetShortMonth());
// Create the first radar plot
$plot = new RadarPlot(array(70, 80, 60, 90, 71, 81, 47));
$plot->SetLegend("Goal");
$plot->SetColor("red", "lightred");
$plot->SetFill(false);
$plot->SetLineWeight(2);
// Create the second radar plot
示例#21
0
 /**
  * construct multigraph
  */
 public function Values($values)
 {
     parent::Values($values);
     $this->multi_graph = new MultiGraph($this->values, $this->force_assoc);
 }