plot: add #:out-file to docs; depend on racket/snip instead of mred
This commit is contained in:
parent
07a7916142
commit
f76a71066e
|
@ -274,14 +274,19 @@ viewed in the DrRacket interactions window.
|
|||
[#:title title string? ""]
|
||||
[#:fgcolor fgcolor (list/c byte? byte? byte) '(0 0 0)]
|
||||
[#:bgcolor bgcolor (list/c byte? byte? byte) '(255 255 255)]
|
||||
[#:lncolor lncolor (list/c byte? byte? byte) '(255 0 0)])
|
||||
[#:lncolor lncolor (list/c byte? byte? byte) '(255 0 0)]
|
||||
[#:out-file out-file (or/c path-string? output-port? #f) #f])
|
||||
(is-a?/c snip%)]{
|
||||
|
||||
Plots @scheme[data] in 2-D, where @scheme[data] is generated by
|
||||
functions like @scheme[points] or @scheme[lines].
|
||||
|
||||
A @scheme[data] value is represented as a procedure that takes a
|
||||
@scheme[2d-view%] instance and adds plot information to it.}
|
||||
@scheme[2d-view%] instance and adds plot information to it.
|
||||
|
||||
The result is a @racket[snip%] for the plot. If an @racket[#:out-file]
|
||||
path or port is provided, the plot is also written as a PNG image to
|
||||
the given path or port.}
|
||||
|
||||
@defproc[(plot3d [data ((is-a?/c 3d-view%) . -> . void?)]
|
||||
[#:width width real? 400]
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
(module view mzscheme
|
||||
(require plot/plplot plot/math mzlib/class mzlib/file mred mzlib/math)
|
||||
(require plot/plplot plot/math mzlib/class mzlib/file
|
||||
racket/draw racket/snip
|
||||
mzlib/math)
|
||||
|
||||
;; including suggested fix from Doug Williams
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user