+ Reply to Thread
Results 1 to 5 of 5

Combining AND OR with COUNTIF

  1. #1
    Registered User
    Join Date
    07-11-2018
    Location
    New Jersey
    MS-Off Ver
    2010
    Posts
    2

    Combining AND OR with COUNTIF

    Hi,

    I am trying to analyze data using COUNTIF to see how many times a certain row goes above the value .02 at the same time as 25% of the column does that. I have managed to write a formula that does that but now I have an issue. Several times in the data the row will be above the .02 value for multiple cells in a row and I do not want the subsequent cells counted but cannot figure out how to do that. There are also times where the cell before is at .02 but the column is not 25% and vice versa.

    I've attached a sheet with an example of the data and what I've been trying to do. Any help would be greatly appreciated. Thanks!
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    11-27-2007
    Location
    New Jersey, USA
    MS-Off Ver
    2013
    Posts
    1,669

    Re: Combining AND OR with COUNTIF

    I created a helper Row and entered following in C6, copied across that to BE6.

    HTML Code: 
    Then used the
    HTML Code: 
    formula. The answer is 9.
    1. Click on the * Add Reputation if you think this helped you
    2. Mark your thread as SOLVED when question is resolved

    Modytrane

  3. #3
    Registered User
    Join Date
    07-11-2018
    Location
    New Jersey
    MS-Off Ver
    2010
    Posts
    2

    Re: Combining AND OR with COUNTIF

    Thanks! That seems to work pretty well but when I tried a row of values it skips one at EE9. I attached the updated sheet. I don't see a reason for it not to count.
    Attached Files Attached Files

  4. #4
    Forum Expert
    Join Date
    11-27-2007
    Location
    New Jersey, USA
    MS-Off Ver
    2013
    Posts
    1,669

    Re: Combining AND OR with COUNTIF

    Because the previous one at ED9 is also above 0.02

    Same way ET9 is not counted because ES9 is above 0.02.
    And FE9 isn't counted either.

    Maybe I missed the logic you want to use.
    I think you want to count the first time Row 9 goes above 0.02 and Row 10 is above 0.25.
    So use this formula instead.
    In C11:
    HTML Code: 
    Drag it across. The result is 16.

  5. #5
    Forum Expert
    Join Date
    11-27-2007
    Location
    New Jersey, USA
    MS-Off Ver
    2013
    Posts
    1,669

    Re: Combining AND OR with COUNTIF

    You can use this formula without any helper Row.

    Use this anywhere, without anything else in Row 11.

    HTML Code: 

+ 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] Combining a countif and a sum formula
    By Slurry Pumper in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-01-2017, 11:35 AM
  2. Combining Countif formulas
    By Roland84 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 12-07-2016, 03:26 PM
  3. [SOLVED] Combining countif formulas
    By tomlannom in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 04-17-2014, 04:45 PM
  4. Combining Subtotal and CountIf
    By jordan2322 in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 02-16-2012, 04:42 AM
  5. Combining a Date Range COUNTIF and a general COUNTIF
    By jacobtom in forum Excel General
    Replies: 1
    Last Post: 09-15-2011, 05:06 PM
  6. Combining COUNTIF and OR won't work
    By Luminary Xion in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 09-30-2008, 04:37 AM
  7. Combining COUNTIF and LEN
    By Guido Cole in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-11-2005, 06:06 PM

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