Line | |
---|
1 | <?php // content="text/plain; charset=utf-8"
|
---|
2 | require_once ('jpgraph/jpgraph.php');
|
---|
3 | require_once ('jpgraph/jpgraph_radar.php');
|
---|
4 |
|
---|
5 | // Some data to plot
|
---|
6 | $data = array(55,80,26,31,95);
|
---|
7 |
|
---|
8 | // Create the graph and the plot
|
---|
9 | $graph = new RadarGraph(250,200);
|
---|
10 |
|
---|
11 | // Add a drop shadow to the graph
|
---|
12 | $graph->SetShadow();
|
---|
13 |
|
---|
14 | // Create the titles for the axis
|
---|
15 | $titles = $gDateLocale->GetShortMonth();
|
---|
16 | $graph->SetTitles($titles);
|
---|
17 | $graph->SetColor('lightyellow');
|
---|
18 |
|
---|
19 | // ADjust the position to make more room
|
---|
20 | // for the legend
|
---|
21 | $graph->SetCenter(0.45,0.5);
|
---|
22 |
|
---|
23 | // Add grid lines
|
---|
24 | $graph->grid->Show();
|
---|
25 | $graph->grid->SetColor('darkred');
|
---|
26 | $graph->grid->SetLineStyle('dashed');
|
---|
27 |
|
---|
28 | $plot = new RadarPlot($data);
|
---|
29 | $plot->SetFillColor('lightblue');
|
---|
30 | $plot->SetLegend("QA results");
|
---|
31 |
|
---|
32 | // Add the plot and display the graph
|
---|
33 | $graph->Add($plot);
|
---|
34 | $graph->Stroke();
|
---|
35 | ?>
|
---|
Note:
See
TracBrowser
for help on using the repository browser.