How can I find the max in each group?

L

LRATLARSON

How can I find the max in each group? The amount of data in each group can
vary. An example is shown below:

Group Value
A 8
A 7
B 3
B 4
B 2
 
J

JE McGimpsey

One way (array-entered: CTRL-SHIFT-ENTER or CMD-RETURN):

=MAX(IF(A1:A100="A",B1:B1000))


Better:

Use a Pivot Table, with Group in the Rows field and Max of Value in the
Data field.
 
D

Don Guillett

this is an ARRAY formula so must be edited/entered with ctrl+shift+enter
instead of just enter.

=MAX(IF(C4:C8="b",D4:D8))
 
A

Aladin Akyurek

D2:

=MAX(IF($A$2:$A$6=C2,$B$2:$B$6))

which must be confirmed with control+shift+enter instead of just wit
enter.

Note that C2 houses a group id like A.

Another option is to build a pivot table from the data.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top