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

Home » Public Forums » archive » Re: Fill intersection of two contours
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Fill intersection of two contours [message #55446] Thu, 23 August 2007 02:23 Go to previous message
burkina is currently offline  burkina
Messages: 32
Registered: February 2005
Member
On Aug 22, 5:22 pm, Brian Larsen <balar...@gmail.com> wrote:
> While I am sure there is a much more elegant solution this one works
> pretty well. I have hacking this kinda thing together before. I
> would love to see the more elegant solution...
>
> dat = dist(100)
> loadct, 0
> contour, dist(100), /fill, nlevels=20
> mask = dat gt 30 and dat lt 40
> loadct, 12
> contour, mask*100, /over, /fill, nlevels=1
> end
>
> To be more specific on the filled region you might need to specify the
> contours in the original plot so that the colored region falls on top
> of it nicely.
>
> Cheers,
>
> Brian
>
> ------------------------------------------------------------ ---------------------
> Brian Larsen
> Boston University
> Center for Space Physics

Hi Brian,

thanks for the reply.
The method you are suggesting me is the one I was thinking about.
Unfortunately, it does not work as I wish, because the 'mask' is not
coincident with the contours' region. It must be the way the contour
procedure works. The two regions are similar, of course, but the
difference is not acceptable for my plot.

I guess the solution should be a graphical one, in the sense that the
contours produced by the contour procedure should be treated as
polygons, with their coordinates, and then, in some way, their
intersection should be found in this way, not in an analytical way.

I hoped this problem had been solved by someone else, since it sould
be quite useful in this kind of plots...

Stefano
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: SOS with Idl
Next Topic: Pson and Psoff with xyouts

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

Current Time: Sat Oct 11 12:29:07 PDT 2025

Total time taken to generate the page: 0.72280 seconds