![](/img/trans.png)
[英]Excel Count Distinct where other columns match and sum of another column = 0
[英]MS Excel count distinct where
我正在使用MS Excel 2013,並且試圖在類似Count的不同地方運行。 這是我的桌子
Name:
jim
james
frank
jillian
jim
john
patrick
jillian
anna
isabelle
我正在嘗試做一個區分,其中名稱以J開頭,這將導致4。這就是我到目前為止的內容。
SUMPRODUCT(1/countif([names],[names])) --- This counts unique names
SUMPRODUCT(--(LEFT([names],1)="j")) --- This counts all names that start with J
我試圖找到一種方法將這兩者結合在一起以計算以J開頭的唯一名稱。在此先感謝。
我想到了。 最終工作了。
= SUMPRODUCT(IF(LEFT([names])=“ j”,1 / COUNTIF([names],[names])))
請試試:
=SUMPRODUCT((LEFT(A2:A99)="J")/COUNTIF(A2:A99,A2:A99&""))
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.