[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Bug in script for plotting
From: |
c. |
Subject: |
Re: Bug in script for plotting |
Date: |
Fri, 8 Feb 2013 13:41:51 +0100 |
On 8 Feb 2013, at 01:59, Ben Abbott <address@hidden> wrote:
> On Feb 7, 2013, at 5:28 PM, stn wrote:
>
>> Hi,
>>
>> this is kind of irritating. It has also probably been discussed before.
>>
>>
>> The plot-command works fine, the plot appears as expected, but on the
>> terminal there is a message
>>
>> gnuplot> nset obj 1;
>> ^
>> line 0: invalid command
>>
>>
>> After lots of googling and some grepping I found this line in
>> /usr/local/share/octave/3.6.3/m/plot/private/__go_draw_axes__.m
>>
>> Only there it says "unset obj". More specifically it says "fputs
>> (plot_stream, "unset obj 1; \\\n");"
>>
>> The problem can be solved by replacing every occurence of "unset obj" in the
>> script with " unset obj".
>>
>> It would appear that the function fputs() does not work correctly and
>> truncates the first character of this string. The solution mentioned above
>> simply adds a space-character, that is then truncated.
>>
>> I would like to suggest checking the matter.
>>
>> Best regards, stn
>
> I've seen this mentioned before, but I do not get this error. For example,
> each of the following work for me.
>
> plot (rand (3))
> surf (peaks ())
> contour (peaks ())
>
> I'm using gnuplot 4.6 patchlevel 1
>
> Can you tell us what version of gnuplot you are using (just in case that is
> involved in some way). Also, can you provide a short script that produces
> the error for you so that we may try to duplicate it?
>
> Ben
Ben,
I run the development Octave version, I have gnuplot 4.6 patch level 1
(installed via macports) and XQuartz 2.7.4 on OSX 10.8.2.
I can consistently reproduce the same issue reported by stn as follows:
1) stop XQuartz
2) plot (randn (3))
the issue can be simply worked around by adding a space in front of all
instances of "unset obj 1" as stn suggested, it seems the first character in
sent to the pipe is getting lost somehow …
c.
- Bug in script for plotting, stn, 2013/02/07
- Re: Bug in script for plotting, Ben Abbott, 2013/02/07
- Re: Bug in script for plotting,
c. <=
- Re: Bug in script for plotting, Ben Abbott, 2013/02/08
- Re: Bug in script for plotting, c., 2013/02/08
- Re: Bug in script for plotting, Ben Abbott, 2013/02/08
- Re: Bug in script for plotting, c., 2013/02/10
- Re: Bug in script for plotting, Benjamin Abbott, 2013/02/10
Re: Bug in script for plotting, Stefan Neumann, 2013/02/08