Very heavy solution: you could link against ROOT, which will do just about anything you want:
- runs on Mac, Windows and Linux
- runs compiled or using the cint interperter
- output to a file in encapsulated postscript, PDF, gif, png...
- display to the screen using several different technologies
- serialize the data in an internal format that can be manipulated later
Sure, its a bit much for most people, but it does do exactly what you asked for. I use it because I know it and it is already on my machines becase I'm that kind of physicist.