Consulting

Results 1 to 2 of 2

Thread: MAX and MIM problem in Arrays

  1. #1
    VBAX Contributor
    Joined
    Aug 2006
    Posts
    120
    Location

    MAX and MIM problem in Arrays

    Hi, Im using some arrays and I need to generate de min value of each array: Im using {=SUM(MIN(ARRAY1,ARRAY2))} But instead of having the sum of the minimum values Im getting the minimum value of both arrays. Example
    Arr1 (1,5,6,2) Arr2 (2,5,2,6) I Need SUM(Arr3 (1,5,2,2)) = 10 but Im getting SUM(Min(((1,5,6,2) , (2,5,2,6))), = sum(min(1,5,6,2,2,5,2,6)), = sum(1) = 1.
    Any Ideas?

  2. #2
    Distinguished Lord of VBAX VBAX Grand Master Bob Phillips's Avatar
    Joined
    Apr 2005
    Posts
    25,453
    Location
    Try this array formula

    =SUM(IF(ARRAY1<ARRAY2,ARRAY1,ARRAY2))
    ____________________________________________
    Nihil simul inventum est et perfectum

    Abusus non tollit usum

    Last night I dreamed of a small consolation enjoyed only by the blind: Nobody knows the trouble I've not seen!
    James Thurber

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •