Page 87 - Excel Data Analysis
P. 87

05 537547 Ch04.qxd  3/4/03  11:52 AM  Page 73






                                                                                     CREATING FORMULAS 4







                                  Formula errors can occur with any formula  TYPE THIS:
                                  you create. If you create a worksheet where
                                  other users input data for analysis, you may
                                                                            =IF (ISERROR(A1/A2), "0", A1/A2)
                                  want to eliminate the display of error
                                  messages in the cells on the worksheets. By
                                  doing this, the errors still occur, but instead of
                                  displaying the error message, you can specify  RESULT:
                                  the value that displays in the cell. For example,
                                  you may want the cell to have a value of zero  With this formula, if the value that the ISERROR
                                  if there is an error. To control the display of  function returns is TRUE, a value of zero displays
                                  the error messages, you modify each formula  in the formula cell; otherwise, the value of
                                  using the combination of the IF function,   dividing A1 by A2 displays in the cell. See
                                  which allows you to check for a condition, and  Appendix B for more information on using the IF
                                  the ISERROR function, which allows you to   and ISERROR functions.
                                  see if a cell contains an error. For example, to
                                  return a value of 0 if there is an error, with the
                                  formula A1/A2:
































                     ■ Excel color-codes each   Note: See the section "Edit   ■ Excel removes the arrows
                     cell in the formula.     Formulas" for more information.  and displays the value of the
                                                                        formula, if an error no longer
                     › Make the appropriate                             exists in the formula.
                     modifications to correct the
                     formula error.


                                                                                                                      73
   82   83   84   85   86   87   88   89   90   91   92