cellMatrix.net
Spreadsheet Modeling and Related Topics

About

Formulas, Charts, and Models Created with Microsoft Excel.
More . . .

Statistics

  • Total Entries - 102
  • Current Viewers - 17

Categories

Recent Comments

Syndicate

Validate

Percent Change Error Trap

To keep the percent change formula from returning errors and/or extreme values, consider a nested IF statement to trap errors or values that fall outside of a certain range. In the example below, "n/a" refers to "not applicable". Errors have been trapped in lines one through three. In line four, the formula returns "n/a" because the absolute value of the change is greater than 200%. This logic is written into the formula to prevent it from returning exteme values.

image

The formula in G4 is below. It is copied from cell G4 into cells G6, G8, G10, and G12.

=IF(ISERROR((E12-F12)/ABS(F12)),"n/a",IF(ABS((E12-F12)/ABS(F12))>1.999,"n/a",(E12-F12)/ABS(F12)))

The second IF looks incomplete… it has greater than, without an argument.

If the error you get in the first if is a div by zero, you can simplify by using =IF(F4=0,“n/a”, etc.

Posted by Jon Peltier  on  04/15  at  02:42 PM

Jon,

Thanks for catching that error . . I’ve made the correction.

John

Posted by  on  04/16  at  08:04 PM


Comment Form

Name: (Required)
E-Mail Address: (Optional)
Location: (Optional)
Web Site Address: (Optional)

Remember my personal information?
Notify me of follow-up comments?

Before submitting your comment, please enter the phrase you see below: