Go Back   Rhinocerus > Newsgroup > Newsgroup comp.lang.* 1 > Newsgroup comp.lang.idl-pvwave

Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 07-03-2012, 03:33 PM
Paul van Delst
Guest
 
Posts: n/a
Default Function graphics /OVERPLOT redefines axis limits after plot with/NODATA

Hello,

I've just "discovered" this weirdness:

IDL> x=plot(lindgen(100)-50,/nodata)
IDL> xi=plot(x.xrange,[0,0],linestyle='dash',/overplot)

On my system, the second command with the /OVERPLOT redefines the yrange of the resulting plot.

The documentation of PLOT, /NODATA states:
"Set this property to 1 to create the graphic, but without any data attached to it. The axes and title (if present) are
also created and displayed."

The documentation of PLOT, /OVERPLOT states:
"Set this property to 1 (one) to place the graphic on top of the existing graphic in the current window."

Now the /NODATA docs state there is no data attached to the plot... but there is some data/information attached to it
since the axis limits are defined and displayed correctly when the plot is initially created.

Note that if the initial /NODATA is not used,

IDL> x=plot(lindgen(100)-50)
IDL> xi=plot(x.xrange,[0,0],linestyle='dash',/overplot)

everything behaves as expected.

In what universe does /OVERPLOT mean:
/ONLY_OVERPLOT_DEPENDING_ON_HOW_THE_EXISTING_GRAPHI C_WAS_CREATED_OTHERWISE_REDEFINE_AXIS_LIMITS.

My IDL:
IDL> print, !version
{ x86 linux unix linux 8.1 Mar 9 2011 32 64}

Sigh. Anyone know if this has been fixed in v8.2?[*]


not-so-cheerily yours,

paulv

[*] With my luck it will have been fixed, but the undocumented /HISTOGRAM keyword to PLOT() will also have been removed
(see my thread from yesterday)
Reply With Quote
Alt Today
Advertising
 
and become member of Rhinocerus
Standard Sponsored Links

  #2 (permalink)  
Old 07-04-2012, 02:25 AM
wlandsman
Guest
 
Posts: n/a
Default Re: Function graphics /OVERPLOT redefines axis limits after plot with /NODATA

On Tuesday, July 3, 2012 11:33:01 AM UTC-4, Paul van Delst wrote:

> Sigh. Anyone know if this has been fixed in v8.2?[*]
>


Yes, it is fixed in V8.2. In V8.1 you can use the following workaround

IDL> x=plot(lindgen(100)-50)
IDL> xi=plot(x.xrange,[0,0],linestyle='dash',/overplot,yrange=x.yrange)

-- Wayne
Reply With Quote
  #3 (permalink)  
Old 07-05-2012, 09:04 PM
Paul van Delst
Guest
 
Posts: n/a
Default Re: Function graphics /OVERPLOT redefines axis limits after plotwith /NODATA

Hi Wayne,

Thanks for the info. I've requested an upgrade.

I did finally come upon the workaround... it just took a while.

cheers,

paulv

On 07/03/12 22:25, wlandsman wrote:
> On Tuesday, July 3, 2012 11:33:01 AM UTC-4, Paul van Delst wrote:
>
>> Sigh. Anyone know if this has been fixed in v8.2?[*]
>>

>
> Yes, it is fixed in V8.2. In V8.1 you can use the following workaround
>
> IDL> x=plot(lindgen(100)-50)
> IDL> xi=plot(x.xrange,[0,0],linestyle='dash',/overplot,yrange=x.yrange)
>
> -- Wayne

Reply With Quote
  #4 (permalink)  
Old 07-05-2012, 09:11 PM
C.E. Ordonez
Guest
 
Posts: n/a
Default Re: Function graphics /OVERPLOT redefines axis limits after plotwith /NODATA

On 7/3/12 9:25 PM, wlandsman wrote:
> On Tuesday, July 3, 2012 11:33:01 AM UTC-4, Paul van Delst wrote:
>
>> Sigh. Anyone know if this has been fixed in v8.2?[*]
>>

>
> Yes, it is fixed in V8.2. In V8.1 you can use the following workaround
>


I don't think it is fixed. I observe the same weirdness in this system:

IDL> print,!version
{ x86_64 darwin unix Mac OS X 8.2 Apr 10 2012 64 64}

But the workaround for 8.1 also works for 8.2.

-Caesar


Reply With Quote
  #5 (permalink)  
Old 07-06-2012, 12:40 AM
wlandsman
Guest
 
Posts: n/a
Default Re: Function graphics /OVERPLOT redefines axis limits after plot with /NODATA

On Thursday, July 5, 2012 5:11:21 PM UTC-4, nerdzoo wrote:
> On 7/3/12 9:25 PM, wlandsman wrote:


> > Yes, it is fixed in V8.2. In V8.1 you can use the following workaround
> >

>
> I don't think it is fixed. I observe the same weirdness in this system:
>

Yeah, I withdraw my statement that the /overplot problem is fixed in V8.2. I must have neglected the /nodata keyword in my quick test. --Wayne
Reply With Quote
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




All times are GMT. The time now is 08:48 PM.


Copyright ©2009

LinkBacks Enabled by vBSEO 3.3.0 RC2 © 2009, Crawlability, Inc.