| View previous topic :: View next topic |
| Author |
Message |
fanouss
Joined: 05 Aug 2008 Posts: 1
|
Posted: Tue Aug 05, 2008 9:14 am Post subject: diagram with two lines |
|
|
Hello,
I would like to create a diagram with two lines. The problem is, each line has different values on the x axis.
for example:
| Code: |
$Dataset1 =& Image_Graph::factory('dataset');
$Dataset1->addpoint(10, 1);
$Dataset1->addpoint(12, 3);
$Dataset1->addpoint(14, 5);
$Plot1 =& $Plotarea->addNew('line', array(&$Dataset1));
|
and:
| Code: |
$Dataset2 =& Image_Graph::factory('dataset');
$Dataset2->addpoint(11, 2);
$Dataset2->addpoint(13, 4);
$Dataset2->addpoint(15, 6);
$Plot2 =& $Plotarea->addNew('line', array(&$Dataset2));
|
I get the values on the x axis exactly in the order as in the code: 10, 12, 14, 11, 13, 15. But the two lines should be parallel too each other and the X-values should be set in ascending order on the x axis.
How can I solve this problem? Thanks for your help.
Greetings
F. |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|