Finding the highest number and notate that in another column

lllr

New Member
Joined
Apr 5, 2010
Messages
6
I know it is easy finding the highest number but I want to find the highest number every 4 rows (there also maybe 2 or more). Once the student row has the highest mark, mark a 1 in the test winner column.

See below. 4 students (rows), 3 tests (columns) and the winners are marked in test winners (columns)

RootScore Rating Results (1H2017)
MarketTest 1Test 2Test 3Test 1 winnerTest 2 winnerTest 3 winner
Student A4.5451
Student B51.54.51
Student C214.5
Student D55511
Student A4.543.51
Student B50.53.51
Student C2.51.51
Student D52411
Student A545111
Student B304
Student C43.54.5
Student D53.5511

<colgroup><col><col><col><col><col><col><col></colgroup><tbody>
</tbody>
 

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.
Consider this:

ABCDEFG
1RootScore Rating Results (1H2017)
2MarketTest 1Test 2Test 3Test 1 winnerTest 2 winnerTest 3 winner
3Student A4.5451
4Student B51.54.51
5Student C214.5
6Student D555111
7Student A4.543.51
8Student B50.53.51
9Student C2.51.51
10Student D52411
11Student A545111
12Student B304
13Student C43.54.5
14Student D53.5511
15

<tbody>
</tbody>
Sheet1

Worksheet Formulas
CellFormula
E3=IF(B3=MAX(OFFSET(B$3:B$6,INT((ROWS(E$3:E3)-1)/4)*4,0)),1,"")

<tbody>
</tbody>

<tbody>
</tbody>



Put the formula in E3, then drag down and to the right as needed.
 
Last edited:
Upvote 0
Hi, to all!

You can use this option too: (drag to down and right):


Book1
ABCDEFG
1RootScore Rating Results (1H2017)
2MarketTest 1Test 2Test 3Test 1 winnerTest 2 winnerTest 3 winner
3Student A4.545 1
4Student B51.54.51
5Student C214.5
6Student D555111
7Student A4.543.51
8Student B50.53.51
9Student C2.51.51
10Student D52411
11Student A545111
12Student B304
13Student C43.54.5
14Student D53.5511
Hoja1
Cell Formulas
RangeFormula
E3=IF(B3=MAX(OFFSET(B3,-MOD(ROWS(E$3:E3)-1,4),,4)),1,"")


And with no volatile functions:


Book1
ABCDEFG
1RootScore Rating Results (1H2017)
2MarketTest 1Test 2Test 3Test 1 winnerTest 2 winnerTest 3 winner
3Student A4.545 1
4Student B51.54.51
5Student C214.5
6Student D555111
7Student A4.543.51
8Student B50.53.51
9Student C2.51.51
10Student D52411
11Student A545111
12Student B304
13Student C43.54.5
14Student D53.5511
Hoja1 (2)
Cell Formulas
RangeFormula
E3=IF(B3=MAX(INDEX(B$3:B$14,N(IF(1,4*INT((ROWS(E$3:E3)-1)/4)+{1;2;3;4})))),1,"")


Blessings!
 
Upvote 0
Sorry one more question. What if we added an overall that indicates which student with the most test wins? It is then counting rows and columns. I assume this is just as easy to calculate the Overall column right?

RootScore Rating Results (1H2017)
MarketTest 1Test 2Test 3Test 1 winnerTest 2 winnerTest 3 winnerOverall
Student A4.545 1
Student B51.54.51
Student C214.5
Student D55511X
Student A4.543.5 1
Student B50.53.511X
Student C2.51.51
Student D52411X
Student A545111X
Student B304
Student C43.54.5
Student D53.5511

<colgroup><col><col><col><col><col><col><col><col></colgroup><tbody>
</tbody>
 
Upvote 0
If I understand you correctly, then this should work:

ABCDEFGHI
1RootScore Rating Results (1H2017)
2MarketTest 1Test 2Test 3Test 1 winnerTest 2 winnerTest 3 winner# of winsOverall
3Student A4.54511
4Student B51.54.511
5Student C214.50
6Student D5551113X
7Student A4.543.511
8Student B50.53.511
9Student C2.51.510
10Student D524112X
11Student A5451113X
12Student B3040
13Student C43.54.50
14Student D53.55112

<colgroup><col style="width: 25pxpx"><col><col><col><col><col><col><col><col><col></colgroup><thead>
</thead><tbody>
</tbody>
Sheet2

Worksheet Formulas
CellFormula
E3=IF(B3=MAX(OFFSET(B$3:B$6,INT((ROWS(E$3:E3)-1)/4)*4,0)),1,"")
H3=SUM(E3:G3)
I3=IF(H3=MAX(OFFSET(H$3:H$6,INT((ROWS(H$3:H3)-1)/4)*4,0)),"X","")

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>



The E3 formula, which is copied to E3:G14, is the same as before. The H3 formula just sums up the wins from columns E:G. Copy it down to H14. Then the I3 formula is just a variation of the E3 formula which looks for the max value in the current set of 4 rows. Copy it to I14.
 
Upvote 0
Hi again!

With Volatile functions:

ABCDEFGH
1RootScore Rating Results (1H2017)
2MarketTest 1Test 2Test 3Test 1 winnerTest 2 winnerTest 3 winnerOverall
3Student A4.5451
4Student B51.54.51
5Student C214.5
6Student D555111X
7Student A4.543.51
8Student B50.53.51
9Student C2.51.51
10Student D52411X
11Student A545111X
12Student B304
13Student C43.54.5
14Student D53.5511

<colgroup><col style="width: 25pxpx"><col><col><col><col><col><col><col><col></colgroup><thead>
</thead><tbody>
</tbody>
Hoja1

Worksheet Formulas
CellFormula
E3=IF(B3=MAX(OFFSET(B3,-MOD(ROWS(E$3:E3)-1,4),,4)),1,"")
H3=IF(SUM(E3:G3)=MAX(MMULT(N(+OFFSET(E3,-MOD(ROWS(H$3:H3)-1,4),,4,3)),{1;1;1})),"X","")

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>

Without Volatile functions:

ABCDEFGH
1RootScore Rating Results (1H2017)
2MarketTest 1Test 2Test 3Test 1 winnerTest 2 winnerTest 3 winnerOverall
3Student A4.5451
4Student B51.54.51
5Student C214.5
6Student D555111X
7Student A4.543.51
8Student B50.53.51
9Student C2.51.51
10Student D52411X
11Student A545111X
12Student B304
13Student C43.54.5
14Student D53.5511

<colgroup><col style="width: 25pxpx"><col><col><col><col><col><col><col><col></colgroup><thead>
</thead><tbody>
</tbody>
Hoja2

Worksheet Formulas
CellFormula
E3=IF(B3=MAX(INDEX(B$3:B$14,N(IF(1,4*INT((ROWS(E$3:E3)-1)/4)+{1;2;3;4})))),1,"")
H3=IF(SUM(E3:G3)=MAX(MMULT(N(INDEX(E$3:G$14,N(IF(1,4*INT((ROWS(H$3:H3)-1)/4)+{1;2;3;4})),N(IF(1,{1,2,3})))),{1;1;1})),"X","")

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>


Blessings!
 
Last edited:
Upvote 0

Forum statistics

Threads
1,214,819
Messages
6,121,741
Members
449,050
Latest member
excelknuckles

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