Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: Library for realtime graphs in perl.

by Discipulus (Canon)
on Oct 17, 2018 at 12:07 UTC ( [id://1224154]=note: print w/replies, xml ) Need Help??


in reply to Library for realtime graphs in perl.

Hello, tobbes,

fortunately the program you have to extend is in Perl ;=)

You can try GD::Graph and additionally you can take a look to doughnut charts with gd:graph where marto points to a useful article.

See also this extract

For the interactive part.. I suppose you need some web interface to achieve interactivity, or a GUI like a Tk program.

L*

There are no rules, there are no thumbs..
Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.

Replies are listed 'Best First'.
Re^2: Library for realtime graphs in perl.
by tobbes (Acolyte) on Oct 17, 2018 at 12:36 UTC
    Thanks. I have looked into GD::Graph, but as I have used it to get output you generate an image from it. Now, I will be needing to regenerate this imagefile at least 10 times per second and I am in doubt as to whether perl can generate images at that rate. Also the user should be able to watch the image as the graph is drawn. There are a number of javascript libraries for this (most notably maybe Google::Charts) but alas the users will have no access to the internet. There are other javascript opitons as well which abandoned for reasons I don't recall at the moment :).

      I don't think ten images per second is unreasonable. Of course, it depends on the amount of CPU you can dedicate to it, the complexity of the images, and how efficiently your code is written, but this article talks about GD generating an image in 0.003110 seconds and some digging in the Wayback Machine indicates that those numbers are from over ten years ago; on a modern CPU it should be faster. (The article was a test of the PHP bindings for LibGD, but it's the same underlying C library, so I don't see any reason why the Perl bindings would be significantly slower.)

        Might be worth investigating then, thank you.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1224154]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (5)
As of 2024-05-18 16:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found