octave-maintainers
[Top][All Lists]
Advanced

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

Re: Plot problem?


From: Ben Abbott
Subject: Re: Plot problem?
Date: Thu, 25 Jun 2009 10:03:50 -0400

On Thursday, June 25, 2009, at 09:53AM, "Robert T. Short" <address@hidden> 
wrote:
>Ben Abbott wrote:
>>
>> On Jun 24, 2009, at 10:04 PM, Robert T. Short wrote:
>>
>>> Ben Abbott wrote:
>>>> On Jun 24, 2009, at 2:50 PM, Robert T. Short wrote:
>>>>>
>>>>> John W. Eaton wrote:
>>>>>> On 16-Jun-2009, Robert T. Short wrote:
>>>>>>
>>>>>> | And on that note.....
>>>>>> | | This may be a gnuplot problem.  I don't know.  I am running 
>>>>>> 4.2 (the | current debian lenny gnuplot package).  I confess to 
>>>>>> being somewhat | overwhelmed by the plot/graphics threads so this 
>>>>>> may have already been | addressed.  If so, I apologize in advance.
>>>>>> | | The attached script is a vastly simplified version of 
>>>>>> something I do a | lot of.  It draws circles with lines between them.
>>>>>> | | I frequently print to encapsulated PostScript or fig, 
>>>>>> depending on | whether I further need to annotate the plot or not.
>>>>>> | | There are two problems: 'axis square' doesn't seem to work and 
>>>>>> line | styles don't print correctly.
>>>>>> | | --- With either 'axis square' or 'axis equal', the axes come 
>>>>>> out unequal | so the circles are smashed.
>>>>>>
>>>>>> I don't see this with the current Octave sources or 3.2.0.  I'm using
>>>>>> gnuplot 4.2 patchlevel 5 on a Debian testing system.
>>>>>>
>>>>>> | --- The on-screen plot comes out with the line styles and colors 
>>>>>> | specified.  The fig file cycles through the colors for both the 
>>>>>> circles | and the lines.  The eps file gets the colors right, but 
>>>>>> not the line styles.
>>>>>>
>>>>>> As I recall, mixing line styles and colors has never really worked
>>>>>> correctly in gnuplot and the behavior is terminal dependent.  But
>>>>>> maybe things have changed lately?  I'm not sure.
>>>>>>
>>>>>> | In MATLAB, I can't do fig files of course, but it gets the eps 
>>>>>> file | right EXCEPT it loses all the colors....
>>>>>>
>>>>>> Did you use -depsc or -deps?
>>>>>>
>>>>>> jwe
>>>>>> k
>>>>>
>>>>> Interesting.
>>>>>
>>>>> I am using 4.2 patchlevel 2, but installed patchlevel 5 and got the 
>>>>> same thing.
>>>>>
>>>>> This is with the tip as of Saturday or so.  Note that a standard 
>>>>> 4/3 monitor ALMOST works, but not quite.
>>>>> This is the difference between using octave and going back to 
>>>>> MATLAB, so I have been playing with gnuplot and looking through the 
>>>>> octave sources to find out what is going on.  I will let you know - 
>>>>> a patch if I can figure it out or a second request if I can't.  
>>>>> MATLAB doesn't really work either though, because I need to do some 
>>>>> fairly complex annotation and way prefer to use xfig for that.
>>>>>
>>>>> Bob
>>>>
>>>> I tried gnuplot-4.2.2, gnuplot-4.2.5, and gnuplot's developers 
>>>> sources, all with Octave's current sources. They each give me 
>>>> perfect circles.
>>>>
>>>> Bob, I notice your script allows the user to "Resize if desired, 
>>>> then press enter" ... By chance are you resizing the window via the 
>>>> mouse and expecting Octave to handle fixing the aspect ratio for you?
>>>>
>>> I tried both resizing and not resizing.  If I resize, the plot is 
>>> redrawn and the circles are screwed up again.
>>>
>>> So, if nobody else is seeing this, I wonder if I have some kind of 
>>> configuration problem?
>>>
>>> Well, don't sweat it.  I will find out what is happening.
>>
>> (Robert, we fell of the list, so I'm replying a second time).
>
>Sorry, I got sloppy and forgot to include the list.  I need to be more 
>careful.
>
>>
>> For display to the screen, I suspect that you see exactly what I see. 
>> Please confirm ...
>>
>> (1) If you do *not* resize the window, you get perfect circles.
>>
>
>No.  If I do not resize, I see smashed circles (ellipses).
>
>> (2) If you *do* resize the window, you get ellipses.
>>
>
>If I resize until the circles look like circles, then I get circles.
>
>> (3) If you *do* resize the window, and the "print -depsc test.eps", 
>> the displayed window and the eps file both have perfect circles.
>>
>If I do *not* resize and "print", then I get ellipses in the print 
>file.  Also, the screen is resized and the circles become ellipses.
>
>If *do* resize and "print", then I get ellipses in the print file.  
>Also, the screen is resized and the circles become ellipses.
>
>"axis square" has NEVER worked for me.  Back in 2.9 I could plot, resize 
>the window until the ellipses turned to circles.  After that EVERY 
>constellation plot had circles and "print" would produce circles.
>
>
>Let me experiment with terminals and such a bit more.  I will create 
>some screen shots and post those.
>

To help isolate the problem, I've attached a zipped gnuplot script.

After unzipping it, if you type ...

    gnuplot -persist debug.gp

Do you get circles or ellipses?

"Circles" -> the problem is with Octave.

"Ellipses" -> the problem is with Gnuplot.

Ben

Attachment: debug.gp.zip
Description: Binary data


reply via email to

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