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

Home » Public Forums » archive » Re: union or overlap of two plots
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: union or overlap of two plots [message #61610 is a reply to message #61607] Tue, 22 July 2008 07:59 Go to previous messageGo to previous message
kedmond is currently offline  kedmond
Messages: 8
Registered: July 2008
Junior Member
Chris,

Thanks for the quick response. Your solution worked amazingly
well....now I have to sit and figure out why! To make the min()
function work, I had to set y1 and y2 equal to their transpose() since
min() wants the data to be in vector form. Once I did that, your
instructions work as stated.

Thanks again.

-Kazem

On Jul 22, 4:31 am, Spon <christoph.b...@gmail.com> wrote:
> On Jul 22, 3:00 am, kedmond <kedm...@gmail.com> wrote:
>
>> Hello,
>>     I have two plots of data on the same axes.  I need to figure out
>> the area of their overlap.  I think defining the data as two polygons
>> and using polyfillv() would help, but I'm not sure about how to do
>> this.  I was also considering finding all of the interceptions between
>> the two plots, and using tsum() to calculate the area of each
>> subsection of overlap.  Anyways, if there's an easier way, I'd
>> appreciate it.
>
>> -kedmond
>
> How about something like this:
>
> plot, x, y1
> oplot, x, y2
>
> ymin = min( [[y1], [y2]], dim=2)
> oplot, x, ymin, thick = 2
>
> auc = int_tabulated(x, ymin)
>
> Regards,
> Chris
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: newbie wants to enforce "array conservation"
Next Topic: protect our programs from others

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

Current Time: Sat Oct 11 03:01:56 PDT 2025

Total time taken to generate the page: 2.67130 seconds