countif

iterate row by row COUNTIF using ArrayFormula on Google Sheets

半城伤御伤魂 提交于 2019-11-30 15:40:09
I am trying to iterate a COUNTIF formula that counts the number of cells in each row containing numbers greater than 4. I am trying to use ArrayFormula to do this but it isn't working. Unfortunately it counts ALL the cells matching the condition across the entire range B2:G39 resulting in 26 being entered in each row of column K rather than row by row count i.e. number of cells >4 in B2:G2 entered in K2, number of cells >4 in B3:G3 entered in K3 This is the formula =ARRAY_CONSTRAIN(arrayformula( if( row(H:H)=1, "Number of cells >4",COUNTIF(A2:G39,">4"))),39,1) Here is a spreadsheet that

Not able to find unique values in excel

南笙酒味 提交于 2019-11-29 15:15:44
I have some data in excel, I want to select unique values based on multiple criteria. The data that I have in excel is Name Medals Year A 2 2017 B 3 2018 C 5 2018 A 1 2016 C 4 2017 B 7 2018 A 1 2017 D 4 2016 I want to get the count of unique names who got medals >2 and <6 and year is 2017 or 2018. So the result that I should get is 2 as B and C satisfy the criteria. I have searched in internet about his and I got some formula using SUMPRODUCT and COUNTIFS, the formula used is =SUMPRODUCT(1/COUNTIFS(A2:A9,A2:A9,B2:B9,">2",B2:B9,"<6",C2:C9,">2016",C2:C9,"<2019" )) But I am getting error in this

Numbering/sequencing sets of same column values

孤者浪人 提交于 2019-11-29 12:58:25
How to do numbering/sequencing for sets of same column values? For example: Col1 Col2 Andy 1 Chad 1 Bill 1 Andy 2 Bill 2 Bill 3 Chad 2 Bill 4 Since Andy got 2 values, I want to number it 1 and 2 in Column 2. For Bill , I want to number it 1, 2, 3 and 4 and so on. You can accomplish this with countif and a sliding range : A B 1 val1 =COUNTIF($A$1:A1, A1) 2 valx =COUNTIF($A$1:A2, A2) and so on. The formula in column B can be dragged down / autofilled in the column. It anchors to the start of the range and only looks as far down as the value we are numbering; COUNTIF is tallying up the matching