help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: dumb terminal problems (re: Octave on Mac)


From: poti
Subject: Re: dumb terminal problems (re: Octave on Mac)
Date: Tue, 10 Jul 2007 15:04:44 -0400
User-agent: Mutt/1.5.13 (2006-08-11)

On 23:33 Sun 08 Jul     , Paul Kienzle wrote:
> 
> On Jul 8, 2007, at 12:30 AM, address@hidden wrote:
> 
> >>
> >>Another thing is that octave.app has been prepared to work like you 
> >>say, but just putting gnuplot into /Applications - don't know if this 
> >>is all that has to be done for that gnuplot package. Try this from 
> >>your Terminal.app
> >>
> >>  bash$ which gnuplot
> >>
> >>if it then says something like 'gnuplot not found' then you need to 
> >>set up that package somehow different. *Maybe* something like an 
> >>'export PATH=$PATH:/<path to your gnuplot binary>' will help?!
> >>
> >
> >It seems the above will not help. The binary inside the package
> >(gnuplot-version.app/Contents/MacOS/gnupolt-version) does not appear to
> >be compiled to accept input from stdin. Rather, it launches a console
> >interface to gnuplot. There is an included binary to pass scripts to 
> >this
> >app. I tried making this interface binary gnuplot, and calling
> >plot(y) from Octave, but this only activated the program with the
> >console and what appeared to be a blank editor page.
> >
> >I tried passing arguments to the binary inside the app, but that also
> >was to no avail, just giving me the new console with a prompt waiting
> >for input.
> 
> 
> In the drawnow.m file 
> (octave.app/Contents/Resources/share/octave/2.9.12/m/plot/drawnow.m) I 
> see the following:
> 
>     if (nargin == 3)
>       fprintf (plot_stream, "set terminal %s\n;", term);
>       fprintf (plot_stream, "set output \"%s\"\n;", file);
>     elseif (isunix () && isempty (getenv ("DISPLAY")))
>       fprintf (plot_stream, "set terminal dumb\n;");
>     elseif (! isempty (h) && strcmp (getenv ("GNUTERM"), "wxt"))
>       fprintf (plot_stream, "set terminal wxt title \"Figure %d\";\n", 
> h);
>     endif
> 
> The problem goes away if I replace this with:
> 
>     if (nargin == 3)
>       fprintf (plot_stream, "set terminal %s\n;", term);
>       fprintf (plot_stream, "set output \"%s\"\n;", file);
>     endif

Do you mean the above substitution will make something like
plot(y), where y=[2 4 6 8]
work from octave with carbon gnuplot from 
 http://www.tucows.com/get/203840_81894 ?

I tried this with no luck. I tried changing the name of pgnuplot, as
described above, with the same behavior.  I then changed the name of 
gnuplot-3.7.1d.app/Contents/MacOS/gnuplot-3.7.1d
to 
gnuplot-3.7.1d.app/Contents/MacOS/gnuplot
 and added it to path. That brought up two gnupolt terminals, but no
 plot. 

-Poti




reply via email to

[Prev in Thread] Current Thread [Next in Thread]