, TIBCO Software
wdunlap tibco.com
From: Ben quant [mailto:ccqu...@gmail.com]
Sent: Monday, May 14, 2012 1:19 PM
To: Steve Lianoglou
Cc: William Dunlap; r-help@r-project.org
Subject: Re: [R] range segment exclusion using range endpoints
Thank you Steve!
This does everything I need (at this point
graphical check do
> >> > plot(x, s, setdiffRanges(x, s))
> >> Are those the numbers you want?
> >>
> >> I find it easier to use standard functions and data structures for this
> >> than
> >> to adapt the cumsum/order idiom to different situations
Bill Dunlap
>> Spotfire, TIBCO Software
>> wdunlap tibco.com
>>
>>
>> > -Original Message-
>> > From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org]
>> On Behalf
>> > Of Ben quant
>> > Sent: Monday, May 14
functions and data structures for this
> than
> to adapt the cumsum/order idiom to different situations.
>
> Bill Dunlap
> Spotfire, TIBCO Software
> wdunlap tibco.com
>
>
> > -Original Message-
> > From: r-help-boun...@r-project.org [mailto:r-help-boun
nt
> Sent: Monday, May 14, 2012 11:07 AM
> To: jim holtman
> Cc: r-help@r-project.org
> Subject: Re: [R] range segment exclusion using range endpoints
>
> Turns out this solution doesn't work if the s range is outside the range of
> the x range. I didn't include tha
Turns out this solution doesn't work if the s range is outside the range of
the x range. I didn't include that in my examples, but it is something I
have to deal with quite often.
For example s1_rng below causes an issue:
x_rng = c(-100,100)
s1_rng = c(-250.5,30)
s2_rng = c(0.77,10)
s3_rng = c(25
Great solution! Thanks!
Ben
On Sat, May 12, 2012 at 12:50 PM, jim holtman wrote:
> Here is an example of how you might do it. It uses a technique of
> counting how many items are in a queue based on their arrival times;
> it can be used to also find areas of overlap.
>
> Note that it would be
Wow, I'll have to study this one for a bit. Thanks!
Ben
On Sat, May 12, 2012 at 3:09 PM, William Dunlap wrote:
> Here is some code that I've been fiddling with for years
> (since I wanted to provide evidence that our main office
> needed more modems and wanted to show how often
> both of them w
Here is some code that I've been fiddling with for years
(since I wanted to provide evidence that our main office
needed more modems and wanted to show how often
both of them were busy). It does set operations and a
bit more on collections of half-open intervals. (Hence
it drops zero-length inter
Here is an example of how you might do it. It uses a technique of
counting how many items are in a queue based on their arrival times;
it can be used to also find areas of overlap.
Note that it would be best to use a list for the 's' end points
> # note the next
10 matches
Mail list logo