Finding the appropriate function

andreaspul

New Member
Joined
Jul 4, 2024
Messages
2
Office Version
  1. 2021
Platform
  1. Windows
Hi. I have data in excel based on 2 sets of variables:
  • groups: the west, west-leaning, non-aligned etc)
  • options: western, abstain, opposite
i have already organised the data in 2 ways:

First by group and then by option, for example:
The West
EVENT 1EVENT 2
Western542
Absent & Abstain051
Opposite01

West-Leaning
EVENT 1EVENT 2
Western370
Absent & Abstain219
Opposite020


And the other way around, ie first by option and then by group, for example:

Western
EVENT 1EVENT 2
The West
54​
2​
West-Leaning
37​
0​
Non-Aligned
32​
0​
Anti-West Leaning
18​
0​
Anti-West
0​
0​


Non-Aligned
EVENT 1EVENT 2
Western
32​
0​
Absent
3​
13​
Abstain
16​
1​
Absent & Abstain
19​
14​
Opposite
0​
37​

I want to find number of events (one column = one event, and there is a large number of them) in which each option (western, absent, opposite) is the greatest between the 3 options, but do this separately for each group (the west, west-leaning etc), in order to fill in the table below. I have no idea how to do that.

NUMBER OF EVENTS WesternAbsent & AbstainOpposite
The West
West-Leaning
Non-Alignedfor example, in this box I want to have the number of events in which "absent-abstain" was greater than "western" and "opposite", but only within the non-aligned group
Anti-West Leaning
Anti-West

I would appreciate your help! Thank you!
 

Excel Facts

When did Power Query debut in Excel?
Although it was an add-in in Excel 2010 & Excel 2013, Power Query became a part of Excel in 2016, in Data, Get & Transform Data.
Good to hear you got the solution.
If you would like to post the solution then it is perfectly fine to mark your post as the solution to help future readers. Otherwise, please do not mark a post that doesn't contain a solution.
 
Upvote 0

Forum statistics

Threads
1,223,893
Messages
6,175,240
Members
452,621
Latest member
Laura_PinksBTHFT

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top