I'm trying to understand and use CMUCL's external programming
interface, but I'm not having much luck with communications.
What I actually want to do is start the gnuplot program and use it to
plot data contained in arrays. So my first attempt is
(setf p (run-program "gnuplot" nil
:wait nil
:input :stream
:output t
:error :output))
This generates a running gnuplot process (according to ps auxw), and I
seem to have a stream:
* (process-input p)
#<Stream for descriptor 9>
I would like to be able to send commands to the gnuplot via this
stream, for instance using format, but this did not work:
* (format (process-input p) "plot sin(x)~%")
NIL
It returned nil, and nothing was plotted. What am I missing?
(Probably something simple). I tried setting the :pty option to t,
and that didn't seem to make any difference.
Cheers,
rif