Hi guys how are you, I'm facing a little challenge in populating the correct value on the Aligned Column on a huge file.
I need to create a formula or a logic that can help me determine the correct value that will be displayed in the Aligned Column.
In Example A you see multiple columns, A1, A2, A3... and A Ind ( this column will agree with the rest of the other columns)
The challenge is to create a way that can help determine the correct values across the multiple columns, the rules are:
-If at least one value is populated among the A1, A2, A3... columns, therefore I will be shown in the Aligned Column, the more same values the better because that reaffirms the correct value to be displayed.
-N/A values will agree with the other values that are in the other columns A1 A2 A3... and A Ind.
If there is a value in the A1 A2 A3 columns... different from the one in the A Ind column, then the A Ind column will agree with the rest of the columns even if there is only one value on the A1 A2 A3.... columns.
| Example A | | | | | | | |
| A1 | A2 | A3 | A4 | A5 | A Ind | A6 | Aligned Column |
| ATA | | ATA | ATA | | ATA | | ATA |
| ATA | | | | | | | ATA |
| ATA | | | | | | | ATA |
| ATA | | ATA | | ATA | | | ATA |
| ATA | | ATA | ATA | N/A | | ATA | ATA |
| | | ATA | | | ATA | | ATA |
| | | ATA | ATA | ATA | | ATA | ATA |
| | | ATA | ATA | N/A | | ATA | ATA |
| | | | ATA | ATA | N/A | | ATA |
| ATA | | ATA | ATA | ATA | ATA | ATA | ATA |
| ATA | | | ATA | ATA | ATA | ATA | ATA |
| | | | ATA | ATA | N/A | | ATA |
| | | | | ATA | | | ATA |
| | | | | ATA | | | ATA |
| | | | | | | ATA | ATA |
| ATA | | ATA | ATA | ATA | | | ATA |
In example B, there is an extra rule to be considered.
If there is a conflicting value across A1 A2 A3... columns and they are repeated the same amount of times (in tie) then we need to mark the Aligned Column as "needs review". BUT, if there are more values repeated values even though one or two columns disagree with it, then we will take the value that is repeated the most.
Remember that Column A Ind will agree with the rest of the values that are shown on the other columns, if there is a specific case when the A Ind Column is the only one with a value on the entire row, then that value will be chosen to be in the aligned column.
Please let me know if you have any questions so I can assist you and I will really appreciate your help for finding a solution to this problem, thanks a lot. have a great day.
| Example B | | | | | | | |
| A1 | A2 | A3 | A4 | A5 | A Ind | A6 | Aligned Column |
| ATA | | ATA | ATA | | ATA | | ATA |
| ATA | | | | | PTA | | ATA |
| ATA | | | | | | | ATA |
| ATA | | ATA | | ATA | PTA | | ATA |
| ATA | | ATA | ATA | N/A | PTA | ATA | ATA |
| | | PTA | | PTA | PTA | | PTA |
| | | ATA | ATA | ATA | N/A | ATA | ATA |
| | | ATA | ATA | ATA | | ATA | ATA |
| | | | ATA | ATA | PTA | | ATA |
| PTA | | PTA | PTA | ATA | N/A | PTA | PTA |
| ATA | | | ATA | ATA | ATA | ATA | ATA |
| | | | ATA | ATA | N/A | | ATA |
| | | | | | PTA | | PTA |
| | | | | PTA | ATA | | PTA |
| | | | | | | ATA | ATA |
| ATA | | PTA | | | | | Needs Review |