ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Alternative to Application.Match (https://www.excelbanter.com/excel-programming/308783-re-alternative-application-match.html)

[email protected]

Alternative to Application.Match
 
I thought about that, but logically, it seems like that would take more
time. My reason is this:

For each element in the first array that I'm trying to match -
I'd have to take the entire second array and go back and forth several
times until if found a number that matched - then I still have to
figure out how many items above and below are equal to that value.

The way I'm doing it - since my arrays are both sorted and I know that
every element in the first array appears in the second (and maybe
multiple times in the first as well)
- by resetting the starting point each time through to be progressively
higher and higher and then bypassing any calc's when it hits a maximum,
I'd think that would be faster


Alan Beban[_2_]

Alternative to Application.Match
 
wrote:

I thought about that, but logically, it seems like that would take more
time. My reason is this:

For each element in the first array that I'm trying to match -
I'd have to take the entire second array and go back and forth several
times until if found a number that matched - then I still have to
figure out how many items above and below are equal to that value.

The way I'm doing it - since my arrays are both sorted and I know that
every element in the first array appears in the second (and maybe
multiple times in the first as well)
- by resetting the starting point each time through to be progressively
higher and higher and then bypassing any calc's when it hits a maximum,
I'd think that would be faster

I posted in the "Still having Application.Match trouble" thread.

Alan Beban


All times are GMT +1. The time now is 12:10 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com