IFERROR in nested ifs?

jencha

New Member
Joined
Nov 10, 2017
Messages
20
Hello All,

I'm using the following formula but want zeros when 0/0, instead getting div/0#

IF(G200<1,(G200-F200)/F200,IF(F200=0,"100%",(G200-F200)/(ABS(F200))))

How can I format this? This is for y/y growth just for context.

Jenny
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.
Just wrap the entire formula in Iferror..

Try
=IFERROR(IF(G200<1,(G200-F200)/F200,IF(F200=0,"100%",(G200-F200)/(ABS(F200)))),0)
 
Upvote 0
I am confused. You say you want 0 when 0/0, but the only way to get that is when F200 is 0.
But in your formula, you are saying that you want to return "100%" when F200 is zero.
So which is it? Do you want 0 or 100% when F200 is zero?

Whatever your choice, checking the value of F200 to see if it is zero is the first thing you want to check. If you do that, your error goes away.
 
Upvote 0
Yes, what this does is returns growth rates that are x/0-1 and 0/x-1 as 100% and -100% respectively. Still pondering as to whether this is the best way to think about it...
 
Upvote 0

Forum statistics

Threads
1,224,828
Messages
6,181,215
Members
453,024
Latest member
Wingit77

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