confused about Pear::Image_Graph

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Greg Bryant

    confused about Pear::Image_Graph

    I'm a bit confused about image_graph - I'm just trying to create a line
    graph with multiple lines, be able to assign the text for the x and y ticks
    and colors for the lines. A legend would be nice, but I can build that
    outside.

    I can create a graph and set values, that works. the setColor method seems
    to do nothing, but then again, I have no idea what it's supposed to accept
    - many of the functions are expecting hard-coded values (e.g. addData
    ($values,"line" ) creates a line graph), so it could be a hard-coded color,
    or an RGB value, or an RGBA value. No clue.

    Then, how do you modify an axis? There are axis constructors, but I see no
    way to relate them to the graph. No "setXAxis" method, no return of an
    "Image_Graph_Ax is" pointer from a function (like addData returns a pointer
    to an Image_Graph_Lin e_Common object.

    In other words, these classes are really poorly documented, I haven't been
    able to find any sample code, and the don't follow any kind of conventions
    for "is related to" relationships as found in oo designs.

    If anyone has recommendations other than Pear, please let me know.

    Thanks,
    Greg
  • Ian.H

    #2
    Re: confused about Pear::Image_Gra ph

    On Wed, 28 Jul 2004 11:31:35 +0000, Greg Bryant wrote:
    [color=blue]
    > I'm a bit confused about image_graph -[/color]


    [ snip ]

    [color=blue]
    > If anyone has recommendations other than Pear, please let me know.[/color]


    Google for 'JPGraph'.. very quick and easy to generate graphs with and a
    large manual with great explanations and details too. Unless I'm doing the
    most basic of graphs which I can hack up quick manually with just GD
    functions, JPGraph is normally my choice of weapon =)



    Regards,

    Ian

    --
    Ian.H
    digiServ Network
    London, UK


    Comment

    • Greg Bryant

      #3
      Re: confused about Pear::Image_Gra ph

      "Ian.H" <ian@WINDOZEdig iserv.net> wrote in
      news:pan.2004.0 7.28.12.45.27.6 3000@bubbleboy. digiserv.net:
      [color=blue]
      >
      > Google for 'JPGraph'.. very quick and easy to generate graphs with and
      > a large manual with great explanations and details too. Unless I'm
      > doing the most basic of graphs which I can hack up quick manually with
      > just GD functions, JPGraph is normally my choice of weapon =)
      >[/color]

      Ah - very nice docs indeed. Thanks for the reccy.

      Comment

      Working...