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

Home » Public Forums » archive » Re: Line plot with arrows
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
Re: Line plot with arrows [message #77779] Mon, 26 September 2011 02:58
Fabzou is currently offline  Fabzou
Messages: 76
Registered: November 2010
Member
Hi,

I think that PARTVELVEC from the IDL Astro Lib is more adapted.

http://idlastro.gsfc.nasa.gov/ftp/pro/plot/partvelvec.pro

Via the /DATA keyword, you may place your arrows the way you want to,
but this may be a bit tricky regarding the directions, I don't know how
PARTVELVEC may react in /DATA space... But probably pretty good I am sure.

The major problem with VELOVECT is that it exepects you to plot nice
regular 2-D Grids, which is probably not the case here.

Besides, PARTVELVEC is highly CG compatible ;)

Fabz

On 09/22/2011 09:37 PM, Russell wrote:
> On Sep 22, 11:20 am, Robin Wilson<ro...@rtwilson.com> wrote:
>> Hi all,
>>
>> I'm trying to use IDL (and specifically David's Coyote Graphics system)
>> to plot a line graph showing the passage of rays of light through a
>> modelled atmosphere. I can easily get the data out to plot a simple line
>> graph which joins up the points that the ray passed through, but I want
>> to be able to put arrows on the lines so that it can be seen which
>> direction the light is going.
>>
>> Is there any (relatively easy) way to put arrows on lines in a line plot
>> in IDL? Ideally I'd like to replace each segment of line with an arrow,
>> but I guess I could have arrows just at each point instead. For the
>> latter I would think of overplotting some points, but I'd need to rotate
>> the arrows correctly each time, and I've no idea how to do that.
>>
>> Any ideas?
>>
>> Robin
>>
>> P.S. David - working on your review now (using the book as a reference
>> for programming today to test it out!)
>> ------------------
>> Robin Wilson
>> A PhD student studying complexity in remote sensingwww.rtwilson.com/academic
>
> Hi Robin.
>
> If I understand you correctly, you have a bunch of data (I'll call
> them x and y) which have vector directions associated with them (call
> them dx and dy). And you want to plot little arrows, where the tail
> of the arrow is at (x,y) and the length and direction of the arrow is
> somehow related to (dx,dy). Correct? If so then have a look at
> velovect.pro
>
> http://physics.nyu.edu/grierlab/idl_html_help/V5.html#wp7875 71
>
> Good luck, Russell
Re: Line plot with arrows [message #77797 is a reply to message #77779] Thu, 22 September 2011 12:37 Go to previous message
Russell[1] is currently offline  Russell[1]
Messages: 101
Registered: August 2011
Senior Member
On Sep 22, 11:20 am, Robin Wilson <ro...@rtwilson.com> wrote:
> Hi all,
>
> I'm trying to use IDL (and specifically David's Coyote Graphics system)
> to plot a line graph showing the passage of rays of light through a
> modelled atmosphere. I can easily get the data out to plot a simple line
> graph which joins up the points that the ray passed through, but I want
> to be able to put arrows on the lines so that it can be seen which
> direction the light is going.
>
> Is there any (relatively easy) way to put arrows on lines in a line plot
> in IDL? Ideally I'd like to replace each segment of line with an arrow,
> but I guess I could have arrows just at each point instead. For the
> latter I would think of overplotting some points, but I'd need to rotate
> the arrows correctly each time, and I've no idea how to do that.
>
> Any ideas?
>
> Robin
>
> P.S. David - working on your review now (using the book as a reference
> for programming today to test it out!)
> ------------------
> Robin Wilson
> A PhD student studying complexity in remote sensingwww.rtwilson.com/academic

Hi Robin.

If I understand you correctly, you have a bunch of data (I'll call
them x and y) which have vector directions associated with them (call
them dx and dy). And you want to plot little arrows, where the tail
of the arrow is at (x,y) and the length and direction of the arrow is
somehow related to (dx,dy). Correct? If so then have a look at
velovect.pro

http://physics.nyu.edu/grierlab/idl_html_help/V5.html#wp7875 71

Good luck, Russell
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: Parallelise FOR loop in IDL
Next Topic: Re: Best way to share 'enum' between various functions

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

Current Time: Wed Oct 08 17:06:18 PDT 2025

Total time taken to generate the page: 0.00582 seconds