Graph in Perl

Discussion in 'Perl Misc' started by jupiter, Jan 13, 2007.

  1. jupiter

    jupiter Guest

    Hi

    I am a beginner. s it possible to draw graph in perl in real time ?


    @nil
     
    jupiter, Jan 13, 2007
    #1
    1. Advertising

  2. jupiter wrote:
    >
    > I am a beginner. s it possible to draw graph in perl in real time ?


    Define "in real time"?

    If you want dynamic updates to a graph as new data comes in then a lot
    will depend on the mechanism by which the graph is being displayed.

    There are many graphing modules on CPAN but these are a batch process,
    taking a set of data and producing an graphical image file (PNG or
    whatever). Of course this process can fairly fast so depending on what
    you mean by "in real time" it may be fast enough.

    For example, if the graph is viewed in a web page, you could have a CGI
    script on a web server that generates a PNG on the fly every time a
    given URL is requested. Simply refeshing the browser view would give
    the impression that the graph was dynamically updating but in fact it's
    being rebuilt from scratch each time.
     
    Brian McCauley, Jan 13, 2007
    #2
    1. Advertising

  3. jupiter

    zentara Guest

    zentara, Jan 13, 2007
    #3
  4. jupiter

    jupiter Guest

    zentara wrote:
    > On 12 Jan 2007 20:44:46 -0800, "jupiter" <>
    > wrote:
    >
    > >Hi
    > >
    > >I am a beginner. s it possible to draw graph in perl in real time ?
    > >
    > >
    > >@nil

    >
    > For a well documented solution, see:
    > http://oss.oetiker.ch/rrdtool/index.en.html
    >
    >
    > There are as many solutions as there are languages.
    > For a simple Perl/Tk example, see:
    > http://perlmonks.org?node_id=577181
    >
    > zentara
    >
    >
    > --
    > I'm not really a human, but I play one on earth.
    > http://zentara.net/japh.html



    thanx for fast n easy reply

    what i want is when i start program it should extract webpage with
    lwpcook module
    process data means clean up n extract vales i want
    make a database to store these values then
    it should do some calculation on data already stored
    display them within program (dont want any graphic file) n update as
    new data comes (using multithreading)

    i am able to extract data but not sure how to handle database issue n
    graph issue as i know perl is not database oriented script language nor
    graphics oriented. so should i do what i want in perl or vb is better
    option?
     
    jupiter, Jan 14, 2007
    #4
  5. jupiter

    zentara Guest

    On 14 Jan 2007 00:48:36 -0800, "jupiter" <>
    wrote:


    >what i want is when i start program it should extract webpage with
    >lwpcook module
    >process data means clean up n extract vales i want
    >make a database to store these values then
    >it should do some calculation on data already stored
    >display them within program (dont want any graphic file) n update as
    >new data comes (using multithreading)
    >
    >i am able to extract data but not sure how to handle database issue n
    >graph issue as i know perl is not database oriented script language nor
    >graphics oriented. so should i do what i want in perl or vb is better
    >option?


    wel, yor righting style makes it hard for me to fig out what u want.

    but since you are already using Perl, with LWP and the Database,
    you could make graphs with many different Perl modules. GD is
    often used.



    --
    I'm not really a human, but I play one on earth.
    http://zentara.net/japh.html
     
    zentara, Jan 14, 2007
    #5
  6. jupiter

    jupiter Guest

    zentara wrote:
    > On 14 Jan 2007 00:48:36 -0800, "jupiter" <>
    > wrote:
    >
    >
    > >what i want is when i start program it should extract webpage with
    > >lwpcook module
    > >process data means clean up n extract vales i want
    > >make a database to store these values then
    > >it should do some calculation on data already stored
    > >display them within program (dont want any graphic file) n update as
    > >new data comes (using multithreading)
    > >
    > >i am able to extract data but not sure how to handle database issue n
    > >graph issue as i know perl is not database oriented script language nor
    > >graphics oriented. so should i do what i want in perl or vb is better
    > >option?

    >
    > wel, yor righting style makes it hard for me to fig out what u want.
    >
    > but since you are already using Perl, with LWP and the Database,
    > you could make graphs with many different Perl modules. GD is
    > often used.
    >
    >
    >
    > --
    > I'm not really a human, but I play one on earth.
    > http://zentara.net/japh.html


    I have seen this module it will create png file I dont want to make a
    file I want this graph to appear within program n update in real time
    as well, means as soon as new data comes it should update graph (data
    will be updated in mintues)
     
    jupiter, Jan 14, 2007
    #6
  7. jupiter

    zentara Guest

    On 14 Jan 2007 08:08:44 -0800, "jupiter" <>
    wrote:


    >
    >I have seen this module it will create png file I dont want to make a
    >file I want this graph to appear within program n update in real time
    >as well, means as soon as new data comes it should update graph (data
    >will be updated in mintues)


    Is this for a cgi program? If so, you will need to create some sort of
    file and update it and refresh your cgi. Maybe you could make some sort
    of flash that would do it.

    Otherwise, if it's a desktop app you want, the Tk script at
    http://perlmonks.org?node_id=577181

    does what you ask. Although you will need to customize it to suit
    your situation.

    zentara


    --
    I'm not really a human, but I play one on earth.
    http://zentara.net/japh.html
     
    zentara, Jan 15, 2007
    #7
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. George Sakkis
    Replies:
    1
    Views:
    477
    Szabolcs Nagy
    Jan 29, 2007
  2. Dr Ann Huxtable

    Missing Graph.h and (Graph.lib) woes - any help

    Dr Ann Huxtable, Dec 21, 2004, in forum: C Programming
    Replies:
    6
    Views:
    673
    Dr Ann Huxtable
    Dec 21, 2004
  3. Jef Driesen
    Replies:
    3
    Views:
    2,621
    mlimber
    Jan 24, 2006
  4. Emilio Mayorga
    Replies:
    6
    Views:
    380
    Martien Verbruggen
    Oct 8, 2003
  5. IRR
    Replies:
    2
    Views:
    460
Loading...

Share This Page