+ Reply to Thread
Results 1 to 3 of 3

Count the pairs (positive and negative) of multiple criterias

  1. #1
    Valued Forum Contributor
    Join Date
    04-13-2011
    Location
    Ottawa, Canada
    MS-Off Ver
    365
    Posts
    1,067

    Count the pairs (positive and negative) of multiple criterias

    Hello Excel Experts,

    In an Accounting world, accountants always post numbers. However, when they want to 'reverse' the post, they'll do so with the opposite sign of the numbers that they had posted.

    My question thus is, what combinations of functions do I need to use in order to return the result either as 1 or 0?
    The pairs the posted numbers and the reverse of it with the same criterias return as 1, else 0.

    For example
    Criteria Column 1 Criteria Column 2 Amount Desired Result
    a 101 10 1
    b 101 10 0 (there's no inverse pair)
    c 101 15 0
    a 101 -10 0 (this has been counted as the pair above)
    a 101 10 0 (this is the 2nd time the same value is posted. But there's no inverse to make it a pair)
    b 101 15 0 (there's no inverse pair)
    c 101 15 0
    c 102 80 1
    c 102 80 1
    c 102 -80 0 (this has been counted as the pair above)
    c 102 80 0 (this is the 3rd time the same value is posted. But there's no inverse to make it a pair)
    c 102 -80 0 (this has been counted as the pair above)
    Last edited by dluhut; 10-31-2017 at 12:24 PM.

  2. #2
    Forum Expert tim201110's Avatar
    Join Date
    10-23-2011
    Location
    Russia
    MS-Off Ver
    2016, 2019
    Posts
    2,357

    Re: Count the pairs (positive and negative) of multiple criterias

    =IFERROR(MATCH(1,INDEX((A2=A3:$A$34)*(B2=B3:$B$34)*(-C2=C3:$C$34),),)+ROW()-1,"")
    not one formula
    Attached Files Attached Files

  3. #3
    Valued Forum Contributor
    Join Date
    04-13-2011
    Location
    Ottawa, Canada
    MS-Off Ver
    365
    Posts
    1,067

    Re: Count the pairs (positive and negative) of multiple criterias

    Thanks Tim!

    And Reps up to you

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Count Positive & Negative numbers
    By Purple Rain in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-09-2015, 05:04 AM
  2. COUNT NEGATIVE and POSITIVE RANGES with NUMBERS
    By vanther in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 01-29-2014, 09:11 AM
  3. [SOLVED] Count Consecutive Positive/Negative numbers
    By Taislin in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-16-2013, 01:02 PM
  4. count the series of consecutive positive/negative values and sum them
    By otage in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 12-12-2012, 12:43 PM
  5. [SOLVED] Positive and negative cell count.
    By Big Rick in forum Excel General
    Replies: 4
    Last Post: 05-01-2012, 02:28 PM
  6. Convert negative to positive in sheet containing both positive/negative numbers
    By sa02000 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-29-2010, 07:52 PM
  7. finding out pairs of positive & negative numbers!
    By via135 in forum Excel General
    Replies: 11
    Last Post: 12-18-2005, 02:27 AM

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1