R
Robert AH Prins
I'm struggling to find a way to count unique values in two non-adjacent columns,
further restricted by the fact that a third column has to have another value. So
for the table below, where the unique values to be counted are in cols 2 & 4 and
the discriminant is in col 1,
1 a col-3 a
1 b col-3 b
1 b col-3 b
1 b col-3 c
1 c col-3 c
1 c col-3 d
2 a col-3 a
2 a col-3 b
2 b col-3 b
2 c col-3 c
the result for 1 should be that there are 4 unique values (a/b/c/d), the result
for 2 should be 3 (a/b/c).
I've come across plenty of "SUMPRODUCT(1/COUNTIF(B1:B10,B1:B10))" type pages,
but doing this over two non-adjacent columns further discriminated by a third,
I'm stuck.
Robert
further restricted by the fact that a third column has to have another value. So
for the table below, where the unique values to be counted are in cols 2 & 4 and
the discriminant is in col 1,
1 a col-3 a
1 b col-3 b
1 b col-3 b
1 b col-3 c
1 c col-3 c
1 c col-3 d
2 a col-3 a
2 a col-3 b
2 b col-3 b
2 c col-3 c
the result for 1 should be that there are 4 unique values (a/b/c/d), the result
for 2 should be 3 (a/b/c).
I've come across plenty of "SUMPRODUCT(1/COUNTIF(B1:B10,B1:B10))" type pages,
but doing this over two non-adjacent columns further discriminated by a third,
I'm stuck.
Robert