Thanks Thanks:  0
Likes Likes:  0
Results 1 to 4 of 4

Thread: Conditional Max

  1. #1
    New Member
    Join Date
    Mar 2002
    Posts
    37
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    I have 2 columns: A with value and B with text. I need to have the maximum value based on one condition (that meets the column B). In other words, it is similar to SUMIF, but it would be a MAXIF (unfortunately, I didnīt find this function).
    It would be great to have a max based on two conditions too....
    Regards,

  2. #2
    MrExcel MVP Aladin Akyurek's Avatar
    Join Date
    Feb 2002
    Location
    The Hague, NL
    Posts
    83,604
    Post Thanks / Like
    Mentioned
    33 Post(s)
    Tagged
    6 Thread(s)

    Default

    On 2002-03-21 10:41, RicardoB wrote:
    I have 2 columns: A with value and B with text. I need to have the maximum value based on one condition (that meets the column B). In other words, it is similar to SUMIF, but it would be a MAXIF (unfortunately, I didnīt find this function).
    It would be great to have a max based on two conditions too....
    Regards,
    What is the condition?

  3. #3
    MrExcel MVP Aladin Akyurek's Avatar
    Join Date
    Feb 2002
    Location
    The Hague, NL
    Posts
    83,604
    Post Thanks / Like
    Mentioned
    33 Post(s)
    Tagged
    6 Thread(s)

    Default

    OK.

    Consider

    {2,"a";3,"a";2,"b";6,"a";8,"b";9,"b";3,"c"}

    in A2:B8.

    =SUMPRODUCT(MAX((B2:B8="a")*(A2:A8)))

    will give you the MAX of the values that are associated with an "a" in B2:B8.


  4. #4
    New Member
    Join Date
    Mar 2002
    Posts
    37
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    On 2002-03-21 10:51, Aladin Akyurek wrote:
    OK.

    Consider

    {2,"a";3,"a";2,"b";6,"a";8,"b";9,"b";3,"c"}

    in A2:B8.

    =SUMPRODUCT(MAX((B2:B8="a")*(A2:A8)))

    will give you the MAX of the values that are associated with an "a" in B2:B8.

    Great!! Thank you very much, Aladin!!

Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

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