views:

75

answers:

5

Is there some sort of application/API with which I can graph sets of numbers(line graph)?

I will be interfacing with an external device which will provide me with some readings(via a custom format through a /dev/cua file) at a rate of about 1000 readings per second. I want to be able to graph this as a line graph.

So I will need to be able to either write out a file by my custom application to load into another application to graph it, or I will need to be able to interface with this application or API (preferably the latter for the flexibility)

Also this must be open source and portable to unix platforms.

If I will be interfacing with an API I prefer C or Ruby as a language.

+3  A: 

ruby gruff probably will do what you want.

ennuikiller
This is pretty good.. I think I would have preferred for having a live interface in GTK or something. but this will work.. (I'll leave it open for a bit longer just to see if anyone else has some ideas)
Earlz
A: 

I have been wanting to try this out:

http://qwt.sourceforge.net/index.html

I am particularly interested in the contour plots. But, it seems to do curves as well.

The Qwt library contains GUI Components and utility classes which are primarily useful for programs with a technical background. Beside a 2D plot widget it provides scales, sliders, dials, compasses, thermometers, wheels and knobs to control or display values, arrays, or ranges of type double.

ccook
+2  A: 

There's also Google Charts' and a Ruby gem that'll let you use Google charts, though I'm not sure if they have a limit on the number of charts you can create:

http://googlecharts.rubyforge.org/

http://code.google.com/apis/chart/

btelles
Just as a note, I just now ended up to analyzing this data and will be using this. I won't change the answer though because it's so old.
Earlz
+2  A: 

If you are using unix I would use gnuplot. I don't know if it comes as a library form, but the executable essentially operates like one, you pipe all your information and data to it on stdin.

whatsisname
I haven't used the Ruby libraries for gnuplot, but the python library works fairly well.
alesplin
A: 

See also Scruffy.

Be aware that with these ImageMagick-based libraries, they have a reputation for leaking memory. Not something you want to use in a long-running process (like a web daemon (Sinatra, Ramaze, etc.)). You'll want to shell out or fork, if so.

Pistos