Re: [racket] Plot to png

2011-01-17 Thread Matthew Flatt
I see that `#:out-file' is missing from the docs, and I'll fix that. At Mon, 17 Jan 2011 14:24:55 +, Noel Welsh wrote: > If you specify out-file as an initialisation parameter I think it will > be saved to the named file. > > #lang scheme > (require plot) > > (plot > (line sin) > #:out-fil

Re: [racket] Plot to png

2011-01-17 Thread Noel Welsh
If you specify out-file as an initialisation parameter I think it will be saved to the named file. #lang scheme (require plot) (plot (line sin) #:out-file "foo.png") HTH, N. On Mon, Jan 17, 2011 at 12:18 PM, Milan Markovic wrote: > Hello everybody, > I looked several times through the docs a

Re: [racket] Plot to png

2011-01-17 Thread Thomas Chust
2011/1/17 Milan Markovic : > [...] > I was wondering if I could save a plot directly to an image file without > having to "fish" it out of the REPL and right click. > [...] Hello Milan, plot views support the convertible protocol. Try something like this: #lang racket/base (require file/conv

Re: [racket] Plot to png

2011-01-17 Thread Matthias Felleisen
Contrary to the docs, a plot-view inherits from image-snip, which means you should be able to get the bitmap and from there you should be able to write things to a file. (See below.) But this is clearly an oversight and calls for an extension. Then again, perhaps I am overlooking things -- Ma

[racket] Plot to png

2011-01-17 Thread Milan Markovic
Hello everybody, I looked several times through the docs and couldn't find anything to solve my problem. I was wondering if I could save a plot directly to an image file without having to "fish" it out of the REPL and right click. I am looking into automatically creating a series of graphs direct