index in



I have two arrays whose rows are uniquely identified by the combination
of two columns. I need to find the row-indices in ARRAY1 of the rows
matching those in ARRAY2.

I am using the following code to provde me with the index.
This works fine for smaller arrays but when I get up to array sizes of
10000 rows or so, execution is noticibally slow.
({enclose[2]ARRAY1[;idCol1 idCol2]) {iota} {enclose}[2]ARRAY2[;idCol1
idCol2]

Are there other/better/faster ways of doing this?

.



Relevant Pages

  • Re: To count number of quadruplets with sum = 0
    ... My attempt uses a different approach: create two sorted arrays, ... and then iterate over them looking for matching ...
    (comp.lang.python)
  • Match using array of column and row references to match with
    ... Can you use the match function or any combination of any function to find in ... intersecting cell's value by matching to arrays of row values or matching to ...
    (microsoft.public.excel.worksheet.functions)
  • Re: Compare Datasets or Arrays
    ... It was called "matching" in that cardpunch concept. ... It is doing going foreward in the arrays by matching everytime the keys of ... it assumes that both arrays are sorted on the key value. ...
    (microsoft.public.dotnet.languages.vb)
  • [HELP] modifying hash
    ... # given a hash of arrays, ... # remove a specified element from the arrays if present ... Isn't there a simpler way to remove the matching ...
    (comp.lang.ruby)
  • Re: Any way to do this faster?
    ... I need to know if there is a match between elements in array1 and array2 and then when there is a match I need to copy the row of the matching element in array2 to a row with the same number as the matching row in array1 to a third array, ... Dim colNumbers As VBA.Collection ... Dim lngNum As Long ... Both arrays are variant arrays and I found I needed to do ...
    (microsoft.public.excel.programming)