[ Index ] |
|
Code source de jpGraph 2.2 |
1 <?php 2 // Example of a stock chart 3 include ("../jpgraph.php"); 4 include ("../jpgraph_stock.php"); 5 6 // Data must be in the format : open,close,min,max 7 $datay = array( 8 34,42,27,45, 9 55,25,14,59, 10 15,40,12,47, 11 62,38,25,65, 12 38,49,32,64); 13 14 // Setup a simple graph 15 $graph = new Graph(300,200); 16 $graph->SetScale("textlin"); 17 $graph->SetMarginColor('lightblue'); 18 $graph->title->Set('Stockchart example'); 19 20 // Create a new stock plot 21 $p1 = new StockPlot($datay); 22 23 // Width of the bars (in pixels) 24 $p1->SetWidth(9); 25 26 // Uncomment the following line to hide the horizontal end lines 27 //$p1->HideEndLines(); 28 29 // Add the plot to the graph and send it back to the browser 30 $graph->Add($p1); 31 $graph->Stroke(); 32 33 ?>
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Sat Nov 24 09:27:55 2007 | par Balluche grâce à PHPXref 0.7 |
![]() |