I have a table like the one below
Place Col 1 Col 2 Col 3
1 yes yes yes
2 no yes yes
3 yes no yes
4 no no no
5 no no no
6 no no no
7 no no no
I need to select the first yes in the the first column, once selected that place cannot be used in the second or third columns. For example the first yes in col 2 cannot be 1 because it was used in column 1 therefore I select the yes in position 2. In the third column we can't select the first or second yes because they have been used in col1 and col 2 therefore the only available first in line yes is number 3. I need this to be driven by formulas i.e. change randomly the order of yes and nos but never have the same yes selected in the same position regardless of column.
For example we can show the yes positions down the bottom like
Col 1 Col 2 Col 3
1 2 3
Under the column 1, use this formula:
=MATCH("yes",B$2:B$8,0),
where B$2:B$8 is the data in the first column.
Under the column 2, use this formula:
=MATCH("yes",IF(ISERROR(MATCH(ROW(C$2:C$8)-ROW(C$2)+1,$B$12:B$12,0)),C$2:C$8,"no"),0)
where B12 is the cell with the first formula.
Make sure you press Ctrl+Shift+Enter to enter this formula.
Drag the second formula to the right for as many columns as you want.
Related
Basically i have a set of data (applications) and i am trying to have a formula which can automatically turn it to a yes for a higher level review based on every 1/10 * 680 (applications)
SO basically If column A says Yes then turn Column B to Yes aswell
But also turn COlumn B to yes if its every 6th or 7th row
If Cell A1 = "Yes" and if "Yes" for every 6th row then in Cell B1 paste:
=IF(A1="Yes","Yes",IF(MOD(ROW(A1),6)<>0,"","Yes"))
Consider this set:
A
B
YES
1
NO
3
NO
3
NO
2
NO
5
YES
2
YES
1
I would like to create a formula that will choose all the values for "YES" from column 1, and for each match, add the values from column 2 (4).
I've attempted this using =SUM(VLOOKUP("YES",A1:B7, 2, FALSE) But this only returns the number of the first value found.
Any ideas how I can do this?
Use SUMIFS:
=SUMIFS(B:B,A:A,"YES")
Excel noob here. Lets say I have a sheet.
.
A
B
C
D
1
Adam
3
No
No
2
Betty
13
Yes
No
3
Chris
12
No
Yes
4
Dave
0
Yes
Yes
5
Emma
1
No
I want to conditionally highlight cells in multiple ways:
if column C and column D both contain the word 'Yes' colour the row green (e.g. match row 4)
if column C and column D are not the same, colour the row yellow (e.g. match rows 2,3)
if column C or D are empty, colour the row red (e.g. match row 5)
I set up two worksheet conditional formatters
=AND(SEARCH("Yes",$C2)>0,SEARCH("Yes",$D2)>0) is set to be green
=$C2<>$D2 is set to be yellow
=OR(ISBLANK($C2),ISBLANK($D2)) is set to be red
However, I'm getting mixed results. I get green rows where C and D are No or where C and D are different. I don't get any formatting for the second or third rules.
I tried just matching column values directly; =$C2="Yes" doesn't match, hence resorting to SEARCH.
Your observed behaviour is because of the commonality between rules 2 & 3, i.e. if C2 differs from D2 then it is, superficially, because the content of those cells differ but, if one of the cells is blank, when the other isn't, then both rules 2 & 3 are satisfied simultaneously.
In the screenshot below, I have made the assumption that 'half-blank' rows are to be identified before 'non-equal' rows:
the formula for 'equal' rows is
=AND(COUNTIF($C1,"*Yes*"),COUNTIF($D1,"*Yes*"))
(COUNTIF() is used because it caters for Yes being found within a longer string of text and, if not found at all, will return 0, which is interpreted, inside the AND() function, as FALSE, whereas if Yes is found then the function will return 1, interpreted as TRUE)
Given the non-independence of your rules 2 & 3 it is important that the rules implemented are prioritised as illustrated in the screenshot, which can be achieved by using the up and down buttons (highlighted) to move the currently-selected rule either up or down.
In below table in Excel, there are multiple columns, attaching 3 column just as an example. There are duplicates in ID column. Col1 has yes/no values.
I want to create a new column which will display Yes in case any value in Col1 is Yes for a particular ID.
E.g. if ID=1, if it contains at least one "yes" value in col1, then new_col should display yes.
If for an ID=3, all No, then new_col=No. I want to build an Excel formula. Please help.
ID Col1 New_Col
1 Yes Yes
1 No Yes
2 Yes Yes
3 No No
3 No No
3 No No
4 No No
Use:
=IF(COUNTIFS(A:A,A2,B:B,"Yes"),"Yes","No")
In excel, and preferably using pivot tables, I want to count the number of occurrences that have a specific value for different line items.
Tom | yes
Tom | no
Max | n/r
Max | yes
Max | yes
Max | no
The pivot table should have two line items (Max/Tom), one column that counts the sum of occurrences of "yes" and "no" and one column that counts only "yes". The result would be that I can say "Max has won 2 out of 3 relevant cases; Tom has won 1 out of 2 relevant cases"
I know how to do it with formulas, but was wondering if using pivot-tables is also a possibility.
If you can add helper columns I would add two, one for yes and one for no. In the yes column (assuming your data starts in cell A1), in C2 type =--(B2="yes") then in D2 type =--(B2="no")
This will return a 1 if the cell is yes or no like follows:
Name Data Yes No
Tom yes 1 0
Tom no 0 1
Max n/r 0 0
Max yes 1 0
Max yes 1 0
Max no 0 1
Then create a pivot table, put Name as Row Labels, then in Values have Sum of Yes and Sum of No
http://oi63.tinypic.com/10z5j55.jpg
Additional fields are not necessary. When creating the pivot table, set Name equal to your Row value and Data for your Columns value. Then, drag the Name field into the Values area and voila! Screenshot attached.