简体   繁体   English

如何根据两列对谷歌表格中的团队进行排名?

[英]How to rank teams in google sheets based on two columns?

Image of the spreadsheet电子表格的图像

I have a spreadsheet with teams I want to rank.我有一个包含我想要排名的团队的电子表格。 I have two columns - the first one is the main criteria teams should be ranked by, and the second one should be a tie-breaker when the first one is equal.我有两列 - 第一列是团队排名的主要标准,第二列应该是当第一列相等时的决胜局。 If values in both columns are equal, teams should share the places.如果两列中的值相等,则团队应共享位置。 So, basically what I try to achieve is at least to rank teams based on two columns like in the "Kinda ok outcome" column.所以,基本上我试图实现的目标是至少根据两列对团队进行排名,例如“Kinda ok outcome”列。 I've tried to do this using the built-in RANK function, but it only works with one column.我尝试使用内置 RANK function 来执行此操作,但它仅适用于一列。 In the best-case scenario, if it's even possible, I would like to format ranked places in a manner provided in the "Perfect outcome" column.在最好的情况下,如果可能的话,我想以“完美结果”列中提供的方式格式化排名位置。

try:尝试:

=ARRAYFORMULA(IF(A2:A="";;RANK(1*(B2:B&C2:C); 1*(B2:B&C2:C); 0)))

在此处输入图像描述


=ARRAYFORMULA(IF(A2:A="";;REGEXREPLACE(""&
 RANK(1*(B2:B&C2:C); 1*(B2:B&C2:C); 0)&"-"&VLOOKUP(
 RANK(1*(B2:B&C2:C); 1*(B2:B&C2:C); 0); SORT({
 RANK(1*(B2:B&C2:C); 1*(B2:B&C2:C); 0)\ IFERROR(
 RANK(1*(B2:B&C2:C); 1*(B2:B&C2:C); 0)+IFERROR(1/(1/(
 COUNTIFS(B2:B&C2:C; B2:B&C2:C; ROW(B2:B); "<="&ROW(B2:B))-1)); 
 "×"))}; 2; 0); 2; 0); "-$"; )))

在此处输入图像描述


for negative numbers:对于负数:

=ARRAYFORMULA(IF(B3:B8="",,RANK(1*((C3:C8&"0000")+D3:D8), 1*((C3:C8&"0000")+D3:D8), 0)))

在此处输入图像描述

For this work, I recommend using a simpler mode, which would be the function SORT :对于这项工作,我建议使用更简单的模式,即 function SORT

=SORT(A2:E15,2,FALSE,3,FALSE)

Your region seems to use ;您所在的地区似乎使用; instead of , so in your specific case it would look like this:而不是,因此在您的特定情况下,它看起来像这样:

=SORT(A2:E15;2;FALSE;3;FALSE)

The result is this:结果是这样的:

在此处输入图像描述

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Google表格:按一列分组并按两列排名 - Google Sheets : Group By one column and Rank by 2 columns 使用 Google 表格过滤两列 - Filtering two columns using Google Sheets Google 工作表根据按变量排序的不同变量对两列求和 - Google sheets sum two columns based off of different variables sorted by variables Google 表格 - 将表格展平为两列,但根据不同的条件返回结果 - Google Sheets - Flattening a table into two columns, but returning results based on varying conditions 谷歌工作表中的两个活动工作表基于单元格比较更新错误 - two active sheets in google sheets update error based on cell comparison 计算 Google Sheets 中两行中包含最大两个差异的列 - Computing the columns containing the largest two differences in two rows in Google Sheets 如何根据 Google 表格中其他两个单元格的比较,使单元格返回值列表中的一个? - How do you make a cell return one of a list of values based on a comparison of two other cells in Google Sheets? 将两列与谷歌表格上的相似字符串进行比较并使用条件格式 - comparing two columns with the similar strings on google sheets and use conditional formatting 在 Google 表格中将两列表转换为一个列表 - Converting two columns table into one column table in Google Sheets 如何将几个 Google Sheets 列转换为 JSON 字符串? - How do I convert a couple of Google Sheets columns into a JSON string?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM