"it uses more levels of nesting than are allowed in the current file format"

mattbird

Active Member
Joined
Oct 15, 2013
Messages
305
Office Version
  1. 2016
I am trying to design a Body Composition Measurement table which works out a persons risk rating by combining Body Mass Index (BMI) and waist circumference (WC). I have been using an 'IF' formula (Excel 07, Win8) which was working well until I got the following message:

"it uses more levels of nesting than are allowed in the current file format"

To make it more complicated I need the two formulas below as one and for the cell to know the difference between Male 'M' and Female 'F' when entered into the gender cell (cell 'E') to give the correct result depending on sex. In the formula below H7 is BMI, I7 is the WC. Females and males work with the same BMI range but the WC is different as you will notes when looking a both formulas.

Does anyone know how to make this work?

Your help is greatly appreciated

Matt

Males
=IF(AND(H7<=18.5,I7<=102),"Increased Risk",
IF(AND(H7>=18.5,H7<24.9,I7<102),"No Increased Risk",IF(AND(H7>=18.5,H7<24.9,I7>=102),"Increased Risk",
IF(AND(H7>=25,H7<29.9,I7<94),"No Increased Risk",IF(AND(H7>=25,H7<29.9,I7>=94,I7<102),"Increased Risk",IF(AND(H7>=25,H7<29.9,I7>=102),"High Risk",
IF(AND(H7>=30,H7<34.9,I7<94),"Increased Risk",IF(AND(H7>=30,H7<34.9,I7>=94,I7<102),"High Risk",IF(AND(H7>=30,H7<34.9,I7>102),"Very High Risk",
IF(AND(H7>=35,H7<39.9,I7<94),"High Risk",IF(AND(H7>=35,H7<39.9,I7>=94,I7<102),"Very High Risk",IF(AND(H7>=35,H7<39.9,I7>102),"Extreme Risk",
IF(AND(H7>=40,I7<94),"Very High Risk",IF(AND(H7>=40,I7>=94),"Extreme Risk","No Result"))))))))))))))

Females
=IF(AND(H7<=18.5,I7<=88),"Increased Risk",
IF(AND(H7>=18.5,H7<24.9,I7<88),"No Increased Risk",IF(AND(H7>=18.5,H7<24.9,I7>=88),"Increased Risk",
IF(AND(H7>=25,H7<29.9,I7<80),"No Increased Risk",IF(AND(H7>=25,H7<29.9,I7>=80,I7<88),"Increased Risk",IF(AND(H7>=25,H7<29.9,I7>=88),"High Risk",
IF(AND(H7>=30,H7<34.9,I7<80),"Increased Risk",IF(AND(H7>=30,H7<34.9,I7>=80,I7<88),"High Risk",IF(AND(H7>=30,H7<34.9,I7>88),"Very High Risk",
IF(AND(H7>=35,H7<39.9,I7<80),"High Risk",IF(AND(H7>=35,H7<39.9,I7>=80,I7<88),"Very High Risk",IF(AND(H7>=35,H7<39.9,I7>88),"Extreme Risk",
IF(AND(H7>=40,I7<80),"Very High Risk",IF(AND(H7>=40,I7>=80),"Extreme Risk","No Result"))))))))))))))
 
Markmzz,

Nearly working the LOOKUP, VLOOKUP and DATE work great the only thing is; again I have learned Excel 2003 only allows 3 Conditional Formats and I need 5.

Cell M2 need to show Increased Risk as yellow, No Increased Risk as illumine Green, High Risk as Orange, Very High Risk as Red and Extreme Risk as Maroon. Or can it be written into the formula ie the VLOOKUP to also copy the colour as well as the text in the cell?

Regards

Matt

I'm glad that the formulas are working.

About Conditional Formats, I don't know how to do that in Excel 2003 without code.

Maybe the link below can helps:

more than 3 conditional format excel 2003 - Microsoft Community

Markmzz
 
Upvote 0

Excel Facts

Get help while writing formula
Click the italics "fx" icon to the left of the formula bar to open the Functions Arguments dialog. Help is displayed for each argument.
A BIT LATE i KNOW BUT i SAW THIS AS A BIT OF A CHALLENGE

Table
Body Mass Index (BMI)
(calculated below)
W1W2W3M1M2M3
Waist CircumferenceWoman < 80cmWomen 80 - 87.9cmWomen >= 88cmMen < 94cmMen 94 - 101.9cmMen >= 102cm
Underweight<18.5No Increased RiskIncreased RiskNo Increased RiskIncreased RiskIncreased RiskIncreased Risk
Healthy Weight18.5 - 24.9No Increased RiskNo Increased RiskNo Increased RiskNo Increased RiskNo Increased RiskIncreased Risk
Overweight25.0 - 29.9Increased RiskNo Increased RiskIncreased RiskNo Increased RiskIncreased RiskHigh Risk
Obese Class I30.0 - 34.9High RiskIncreased RiskHigh RiskIncreased RiskHigh RiskVery High Risk
Obese Class II35.0 - 39.9High RiskHigh RiskVery High RiskHigh RiskVery High RiskExtreme Risk
Obese Class III>39.9999Very High RiskVery High RiskExtreme RiskVery High RiskExtreme RiskExtreme Risk
GenderHeight (cm)Weight (Kg)BMIWC (cm)BMI CatergoryOverall Health Risksex/waistcirc
M1638030.193Obese Class IIncreased RiskM93
XXXXXX***********
THE TWO CELLS MARKED XXX ARE CALCULATED
M93 IS A CONCATENATION OF SEX AND WAIST CIRCUMFERENCE
THE LOOKUP TABLE BELOW IS USED TO RETURN THE APPROPRIATE HEALTH RISK FACTOR IN THE ROW ABOVE (MARKED *****)
sex/waistcircUNDERWEIGHTHEALTHYWEIGHTOVERWEIGHTOBESECLASS1OBESECLASS2OBESECLASS3
M50Increased RiskNo Increased RiskNo Increased RiskIncreased RiskHigh RiskVery High Risk
M94Increased RiskNo Increased RiskIncreased RiskHigh RiskVery High RiskExtreme Risk
M102Increased RiskIncreased RiskHigh RiskVery High RiskExtreme RiskExtreme Risk
M999Increased RiskIncreased RiskHigh RiskVery High RiskExtreme RiskExtreme Risk
W40No Increased RiskNo Increased RiskIncreased RiskHigh RiskHigh RiskVery High Risk
W80Increased RiskNo Increased RiskNo Increased RiskIncreased RiskHigh RiskVery High Risk
W88No Increased RiskNo Increased RiskIncreased RiskHigh RiskVery High RiskExtreme Risk
W999No Increased RiskNo Increased RiskIncreased RiskHigh RiskVery High RiskExtreme Risk

<colgroup><col><col><col><col><col><col><col><col><col><col></colgroup><tbody>
</tbody>
 
Upvote 0

Forum statistics

Threads
1,214,947
Messages
6,122,411
Members
449,081
Latest member
JAMES KECULAH

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