forked from halo-battle/game
Version 1.9g
This commit is contained in:
parent
d028822d0b
commit
4c9814a99c
800 changed files with 237325 additions and 1949 deletions
30
artichow/examples/site/scatter-002.php
Normal file
30
artichow/examples/site/scatter-002.php
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
<?php
|
||||
|
||||
require_once "../../ScatterPlot.class.php";
|
||||
|
||||
$graph = new Graph(300, 240);
|
||||
|
||||
$graph->title->set('Simple ScatterPlot');
|
||||
$graph->shadow->setSize(4);
|
||||
|
||||
$y = array(1, 1.3, 1.8, 1.6, 10, 7, 8, 3, 4, 2, 4);
|
||||
$x = array(0.5, 0.7, 0.65, 0.9, 0.5, 1.5, 4, 3, 5, 2, 2);
|
||||
|
||||
$plot = new ScatterPlot($y, $x);
|
||||
$plot->setBackgroundColor(new Color(255, 245, 220));
|
||||
|
||||
$plot->mark->setSize(15);
|
||||
$plot->mark->setFill(
|
||||
new RadialGradient(
|
||||
new LightRed,
|
||||
new Red
|
||||
)
|
||||
);
|
||||
|
||||
$plot->setSpace(6, 6, 6, 0);
|
||||
$plot->setPadding(25, NULL, 40, 20);
|
||||
|
||||
$graph->add($plot);
|
||||
$graph->draw();
|
||||
|
||||
?>
|
||||
Loading…
Add table
Add a link
Reference in a new issue