comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » plot position keyword
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
plot position keyword [message #89402] Tue, 07 October 2014 12:46
Mark Quigley is currently offline  Mark Quigley
Messages: 8
Registered: August 2009
Junior Member
I haven't found this in the documentation so I thought I'd post it here, my apologies is this is old news.



I have a routine that creates an array of position vectors, something like what is done with !p.multi=[0,2,2], with a few bells and whistles which don't matter here. For example:

pos = sub_multipos(2,3)
plot,findgen(10),pos = pos[*,NN] ;where NN is 0 to 5.



What I want to do to use the pos array if it exists, or the position defined by !p.multi if is doesn't.

It turns out that this works:

!p.multi=[0,2,2] at some point earlier....


pro something, arr,pos

;pos not defined
pos = n_elements(pos) eq 0 ? [!null,!null,!null,!null] : pos
plot,arr,pos=pos

arr is plotted where it should be according to !p.multi.
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Problem with mpfit.pro
Next Topic: Google Protocol buffers

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 11:44:17 PDT 2025

Total time taken to generate the page: 0.00454 seconds