问题描述
我有一列列出数字的列。如何选择一列中前30%的平均值: '价值'
10
9
8
7
6
5
4
3
2
1
所以,前30%是'10,9,8',平均值是(10 + 9 + 8)/ 3 = 9
在任何版本的excel中,您可以使用与Sean的建议相同的SUMIF / COUNTIF,即
= SUMIF(A1:A10,>& PERCENTILE(A1:A10,0.7))/ COUNTIF(A1:A10, & PERCENTILE(A1:A10,0.7))
或较短的数组公式
= AVERAGE(IF(A1:A10> PERCENTILE(A1:A10,0.7),A1:A10))
确认使用CTRL + SHIFT + ENTER
这些都应该给出相同的结果
I have a column that lists bunch of numbers. How can I select the average of top 30% of the values in one column:
'Values'
10
9
8
7
6
5
4
3
2
1
so, the top 30% is '10, 9, 8' and the average is (10+9+8)/3 = 9
In any version of excel you can use either a SUMIF/COUNTIF along the same lines as Sean's suggestion, i.e.
=SUMIF(A1:A10,">"&PERCENTILE(A1:A10,0.7))/COUNTIF(A1:A10,">"&PERCENTILE(A1:A10,0.7))
or a shorter "array formula"
=AVERAGE(IF(A1:A10>PERCENTILE(A1:A10,0.7),A1:A10))
confirmed with CTRL+SHIFT+ENTER
These should all give identical results
这篇关于在一列中平均获得前30%的值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!