Doubt in nested if

karti1986

Board Regular
Joined
Jun 24, 2014
Messages
60
Hi All

Im trying to make a big fuss of nothing.. hitting my head instead of thinking calm. Appreciate any help on my issue.
I'm trying to rate a set of servers with respect to the no. of alerts which they throw.
Rating being 1-Red, 2-Amber, 3-Green...

Overall average here being = 7, server 1 to server 23 are 1-Red
Take an average from Server 24 to Server 41, which is 5 here.( point where the no. of alerts gets lesser than the overall average(7))
and rate the servers which are in between overall average(7) and the new average(5) as 2 -Amber
Servers below new average(5) are 3-Green
Please help me to accomplish this one..

[TABLE="width: 215"]
<colgroup><col><col></colgroup><tbody>[TR]
[TD]Server 1[/TD]
[TD]13[/TD]
[/TR]
[TR]
[TD]Server 2[/TD]
[TD]12[/TD]
[/TR]
[TR]
[TD]Server 3[/TD]
[TD]10[/TD]
[/TR]
[TR]
[TD]Server 4[/TD]
[TD]10[/TD]
[/TR]
[TR]
[TD]Server 5[/TD]
[TD]10[/TD]
[/TR]
[TR]
[TD]Server 6[/TD]
[TD]10[/TD]
[/TR]
[TR]
[TD]Server 7[/TD]
[TD]9[/TD]
[/TR]
[TR]
[TD]Server 8[/TD]
[TD]9[/TD]
[/TR]
[TR]
[TD]Server 9[/TD]
[TD]9[/TD]
[/TR]
[TR]
[TD]Server 10[/TD]
[TD]9[/TD]
[/TR]
[TR]
[TD]Server 11[/TD]
[TD]9[/TD]
[/TR]
[TR]
[TD]Server 12[/TD]
[TD]9[/TD]
[/TR]
[TR]
[TD]Server 13[/TD]
[TD]9[/TD]
[/TR]
[TR]
[TD]Server 14[/TD]
[TD]9[/TD]
[/TR]
[TR]
[TD]Server 15[/TD]
[TD]8[/TD]
[/TR]
[TR]
[TD]Server 16[/TD]
[TD]8[/TD]
[/TR]
[TR]
[TD]Server 17[/TD]
[TD]8[/TD]
[/TR]
[TR]
[TD]Server 18[/TD]
[TD]8[/TD]
[/TR]
[TR]
[TD]Server 19[/TD]
[TD]7[/TD]
[/TR]
[TR]
[TD]Server 20[/TD]
[TD]7[/TD]
[/TR]
[TR]
[TD]Server 21[/TD]
[TD]7[/TD]
[/TR]
[TR]
[TD]Server 22[/TD]
[TD]7[/TD]
[/TR]
[TR]
[TD]Server 23[/TD]
[TD]7[/TD]
[/TR]
[TR]
[TD]Server 24[/TD]
[TD]6[/TD]
[/TR]
[TR]
[TD]Server 25[/TD]
[TD]6[/TD]
[/TR]
[TR]
[TD]Server 26[/TD]
[TD]6[/TD]
[/TR]
[TR]
[TD]Server 27[/TD]
[TD]6[/TD]
[/TR]
[TR]
[TD]Server 28[/TD]
[TD]6[/TD]
[/TR]
[TR]
[TD]Server 29[/TD]
[TD]6[/TD]
[/TR]
[TR]
[TD]Server 30[/TD]
[TD]5[/TD]
[/TR]
[TR]
[TD]Server 31[/TD]
[TD]5[/TD]
[/TR]
[TR]
[TD]Server 32[/TD]
[TD]5[/TD]
[/TR]
[TR]
[TD]Server 33[/TD]
[TD]5[/TD]
[/TR]
[TR]
[TD]Server 34[/TD]
[TD]5[/TD]
[/TR]
[TR]
[TD]Server 35[/TD]
[TD]5[/TD]
[/TR]
[TR]
[TD]Server 36[/TD]
[TD]5[/TD]
[/TR]
[TR]
[TD]Server 37[/TD]
[TD]5[/TD]
[/TR]
[TR]
[TD]Server 38[/TD]
[TD]5[/TD]
[/TR]
[TR]
[TD]Server 39[/TD]
[TD]5[/TD]
[/TR]
[TR]
[TD]Server 40[/TD]
[TD]5[/TD]
[/TR]
[TR]
[TD]Server 41[/TD]
[TD]5[/TD]
[/TR]
</tbody>[/TABLE]

Thanks in advance guys
 

Excel Facts

How to fill five years of quarters?
Type 1Q-2023 in a cell. Grab the fill handle and drag down or right. After 4Q-2023, Excel will jump to 1Q-2024. Dash can be any character.
Something like this? Not sure what new average means??

=IF(B1>ROUNDDOWN(AVERAGE(B:B),0),"RED",IF(B1=ROUNDDOWN(AVERAGE(B:B),0),"AMBER","GREEN"))
 
Upvote 0
It didnt work buddy..
my sequence of actions to be
1. take overall average of no. of events Server1 to Server41 (Average=7)
2. compare no. of events with overall average(7), events greater than 7 are RED
3. a breaking point where the condition fails.. here server 24 is the breaking point where the condition fails
4. average of no. of events from the breaking point to end (here Server24 to Server41) which is 5
5. another condition - no. of events which lies between Overall Average(7) and the new average(5) to be AMBER
6. rest of the servers with events less than new average(5) to be GREEN.
a macro to attain this will helpful too..
 
Upvote 0

Forum statistics

Threads
1,226,453
Messages
6,191,136
Members
453,642
Latest member
jefals

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