Excel Final UPES

Embed Size (px)

Citation preview

  • 7/31/2019 Excel Final UPES

    1/259

    1

    Welcome to 2 days

    Workshopon

    Financial Modelingby using Spreadsheets

    Shivaraj Bhor BE, PG (NITIE), CWADeputy Manager (Mgmt Acct Cell)GAIL (India) Limited

  • 7/31/2019 Excel Final UPES

    2/259

    Exploring Office 2003 - Grauer and Barber 2

    Objective of the Workshop

    Enabling Business Managers:

    Actively learn : To Design, Develop / Implementspreadsheet real-world models

    Put theory into Practice: By understandingModel Formulation

    Increase Analytical Skills: By Exploiting

    Mathematical techniques

  • 7/31/2019 Excel Final UPES

    3/259

    3

    Introduction to

    Excel

  • 7/31/2019 Excel Final UPES

    4/259

  • 7/31/2019 Excel Final UPES

    5/259

    Exploring Office 2003 - Grauer and Barber 5

    Introduction to Spreadsheets

    Workbook contains one or more worksheets

    Spreadsheet a computerized ledger

    Rows and Columns

    Columns identified with alphabetic headings Rows identified with numeric headings

    Intersection of row and column forms a cell.

  • 7/31/2019 Excel Final UPES

    6/259

    Definitions

    General formatit is the default format for numericentries and displays a number according to the way it wasoriginally entered.

    Number formatdisplays a number with or without the1000 separator and with any number of decimal places.

    Negative numbers can be displayed with parentheses and/or can be shown in red.

    Scientific format which displays a number as a decimalfraction followed by a whole number exponent of 10; for

    example the number 12345 would appear as 1.2345E+04.The exponent, +04 in the example, is the number of placesthe decimal point is moved to the left. Very small numbershave negative exponents.

    6

  • 7/31/2019 Excel Final UPES

    7/259

    Exploring Office 2003 - Grauer and Barber 7

    An Excel Workbook

    Title bar shows name

    of workbook

    Standard toolbar

    Menu bar gives lists ofcommands

    Formatting toolbar

  • 7/31/2019 Excel Final UPES

    8/259

    Exploring Office 2003 - Grauer and Barber 8

    Rows, Columns, and Cells

    Cell referenced bycolumn, then number

    Active cell surroundedby heavy border

    Column headings aboveeach column. Columnsdesignated with letters

    Row headings to the leftof each row. Rowsdesignated with numbers

  • 7/31/2019 Excel Final UPES

    9/259

    Exploring Office 2003 - Grauer and Barber 9

    Types of Cell EntriesConstants & Functions

    Constant an entry that does not change

    Can be a numeric value or descriptive text

    Functions a predefined computational task Users cannot change them

    =AVERAGE(B3:B7)

    =SUM(A1:B2)

    Student Adam 100

  • 7/31/2019 Excel Final UPES

    10/259

    Exploring Office 2003 - Grauer and Barber 10

    Formulas and Constants

    Formulas and Constants

    Constantis entries that does not change. It may be anumber, such as a grade on an exam, or it may bedescriptive text (name).

    Formula is combination of numeric constants, cellreferences, arithmetic operators, and/or functions.

    Always begins with an equal sign

    =(B3+B4+B5/5)

    =AVERAGE(B3:B7)

  • 7/31/2019 Excel Final UPES

    11/259

    Exploring Office 2003 - Grauer and Barber 12

    Toolbars

    Appear beneath the menu bar

    Contain buttons that perform commonly-used commands

    Standard toolbar buttons correspond to most basiccommands in Excel

    Examples include opening, closing, and saving aworkbook

    Formatting toolbar buttons correspond to commonformatting operations

    Examples include boldface and cell alignment

  • 7/31/2019 Excel Final UPES

    12/259

    WorksheetBasics

    13

  • 7/31/2019 Excel Final UPES

    13/259

    14

    Worksheets

    Excels mainscreen is called aworksheet.

    Each worksheet iscomprised ofmany boxes,

    called cells.

    5

  • 7/31/2019 Excel Final UPES

    14/259

    15

    Organize Information

    You can organizeinformation bytyping a singlepiece of data intoeach cell.

  • 7/31/2019 Excel Final UPES

    15/259

    16

    How to Enter Information

    17

  • 7/31/2019 Excel Final UPES

    16/259

    17

    Selecting a Cell

    Select a cellby clicking on itonce (dont

    double click).

    You can movefrom cell to cellwith the arrowkeys or bypressing the

    Enter key.

    18

  • 7/31/2019 Excel Final UPES

    17/259

    18

    Entering Information / The Formula Bar

    To enter information ina cell, just start typing.

    When you are doneeither

    Press the Enter Key

    Press an arrow key Click on the check

    button (only visiblewhen entering datainto a cell)

    The information in theselected cell is alsodisplayed in theformula bar abovethe worksheet.

    19

  • 7/31/2019 Excel Final UPES

    18/259

    19

    Double Click to Modify a Cell

    To modify thecontents of a celldouble click on thecell.

    Then use the right,left arrow keys andthe Insert and Deletekeys to modify the

    data. When you are done:

    Press the Enter keyor

    Click on the check box.

    Double click to

    change hi there to

    hello there

  • 7/31/2019 Excel Final UPES

    19/259

    20

    Names of Rows, Columns and

    Cells

    21

  • 7/31/2019 Excel Final UPES

    20/259

    21

    Column Names (letters) & Row Names(numbers)

    The columnsof theworksheet are

    named withletters

    The rows are

    named withnumbers

    Selected

    Cell

    22

  • 7/31/2019 Excel Final UPES

    21/259

    22

    Cell Names (ex. B4)

    The name of a cell is a combinationof the Letter Of The Column thatthe cell is in followed by theNumber Of The Row that the cellis in.

    Example: the selected cell in thepicture is named B4 (NOT 4B)

    Excel automatically shows the thename of the currently selectedcell in the name box (locatedabove the worksheet).

    The letter mustcome first (i.e. B4,

    NOT 4B) and there may NOT beany spaces between the letter andthe number.

    We will learn later why it isimportant to understand how toname cells.

    Name

    Box

    Selected

    Cell

    23

  • 7/31/2019 Excel Final UPES

    22/259

    23

    Information that is too wide for a cell The word Name is in cell

    A5 The words Hours Worked

    are in cell B5 (NOT in cellC5). However, since theinformation is too wide for

    cell B5, it looks like itextends into cell C5.

    You can determine that theinformation is really onlyINcell B5 by selecting cellB5 and looking at theformula bar and thenselecting cell C5 andlooking at the formula bar.

    Hours

    Worked is

    in cell B5

    (look at

    formula bar)

    Hours

    Worked is

    NOT in cell

    C5 (formula

    bar is empty)

    24

  • 7/31/2019 Excel Final UPES

    23/259

    24

    Information that is Chopped Off If there is

    information in thecell to the right, thenthe original cell stillcontains all of thedata, but the dataappears to be

    chopped off.

    You can see the

    complete data byselecting the cell and

    looking in the formula

    bar.

  • 7/31/2019 Excel Final UPES

    24/259

    25

    Change the Width of a Column or

    the Height of a Row

    26

  • 7/31/2019 Excel Final UPES

    25/259

    26

    Make a column wider

    To make Column B wider,point the cursor to thecolumn separatorbetween columns B andcolumn C.

    The cursor changes to aDouble headed arrow.

    Now, click the left mousebutton and without

    letting go of the button,drag the separator to theright to make the columnwider (or to the left to make thecolumn narrower).

    Column is now wider

    Drag column

    separator to the

    right

    27

  • 7/31/2019 Excel Final UPES

    26/259

    27

    Getting the Exact Width

    To get the exact width,double click on theseparator instead ofdragging it.

    Column is now EXACTLYthe correct width

    Double click here

    28

  • 7/31/2019 Excel Final UPES

    27/259

    28

    Resizing a Row

    Make arow talleror shorterbydragging

    theseparatorbetweenthe rows.

    Click anddrag hereto resize

    row 5.

    Row is nowtaller

    29

    d ll

  • 7/31/2019 Excel Final UPES

    28/259

    9

    Putting an Enter inside a cell To add a new line

    inside a cell Double click insidethe cell where youwant the new line.

    Press Ctrl-Enter (i.e.

    hold down the Alt keyand press Enter whilestill holding downCtrl).

    When you are done

    editing, press Enter(without holdingdown Alt) to acceptthe changes.

    Step 1: Originally

    Hours Worked

    is on one line.

    Step 2: Double click

    to edit cell and thenpress Alt-Enter

    Step 3: Press Enter

    (without Alt) to

    accept the changes.

  • 7/31/2019 Excel Final UPES

    29/259

    30

    Basic Formatting

    (e.g. bold, colors, fonts, etc)

    31

  • 7/31/2019 Excel Final UPES

    30/259

    Formatting Cells

    Selectone or more cells and then click on any of the formatting buttons

    (see below) to change the formatting of the selected cells. Formatting buttons:

    fontname

    fontsize

    bold

    italics

    underline

    center & merge cells(will explain later)

    center

    right justifyleft justify

    These change the waynumbers are displayedin cells. (these dont

    affect words).

    show as currency(ex. 1000.507 becomes $1000.50)

    show with commas (e.g.12345 becomes 12,345)

    show as percent (ex.0.5 becomes 50%)

    remove indent

    show fewer decimal points (ex.10.507 is displayedas 10.51)

    show more decimal points (ex.10.507 is displayedas 10.5070)

    indent within cell

    put border around cell(s)color of cell

    color oftext in cell

    click ondownward

    pointing arrowsfor other colors

    and borderstyles

    click ondownward

    pointing arrowsfor other font

    names andsizes

    32

  • 7/31/2019 Excel Final UPES

    31/259

    Example unformatted worksheet

    Unformatted worksheet see next slide for formatting.

    33

  • 7/31/2019 Excel Final UPES

    32/259

    Example making cells bold Click on cell A1 and drag to cell A3.

    Then press the Bold button to make cells A1,A2,A3 bold. You could also press the font or background color buttons to change thecolor or apply any other formatting you like (this is not shown below).

    34

    Oth W f S l ti M Th

  • 7/31/2019 Excel Final UPES

    33/259

    Other Ways of Selecting More ThanOne Cell

    To select a large range of cells, click on theupper left cell in the range. Then hold the shiftkey and click on the lower right cell in the

    range. You can select different non-contiguous areas

    of cells by holding down the Ctrl key while

    clicking and dragging.

    35

  • 7/31/2019 Excel Final UPES

    34/259

    Selecting Non-Contiguous Ranges

    Click anddrag toselect thefirstrange.

    Ctrl-click

    and dragto selectadditional ranges

    (This cell is also selected

    even though it appears

    white).

    36

    Selecting entire Ro s entire Columns

  • 7/31/2019 Excel Final UPES

    35/259

    Selecting entire Rows, entire Columnsor all cells on the worksheet.

    To select an entire column, click on the letter for thecolumn header. To select several columns, click on theheader for the first column and drag to the right.

    To select an entire row, click on the number for therow header. To select several rows, click on the headerfor the first row and drag down.

    To select all of the cells on the spreadsheet, click on

    the upper left hand corner of the spreadsheet (wherethe column headers meet the row headers)

    37

    S l E i C l /R /W k h

  • 7/31/2019 Excel Final UPES

    36/259

    Select Entire Columns/Rows/WorksheetTo selectENTIRE COLUMN B

    click on B column header

    To selectCOLUMNS B,C,Dclick on B column header and drag to right

    To selectCOLUMNS B,C and F,G,H click on B column header, drag to right, then Ctrl-Click on F column header and drag right

    To selectENTIRE ROW 2click on 2 row header

    To selectROWS 2,3 and 5,6,7 click on 2 row header, drag down,

    then Ctrl-Click on 5 row header and drag down

    To selectENTIRE WORKSHEETclick on select worksheet button

    (in corner between 1 and A buttons)

    ClickClick

    dragClick

    drag

    Click and drag down

    then Ctrl-Click

    and drag down

    Clickdrag

    Ctrl-

    ClickClick

    38

  • 7/31/2019 Excel Final UPES

    37/259

    Example - continued

    Step 1: Clickon row headerfor row 5

    Step 2:Ctrl-click onrow-header forrow 11

    Step 3: PressBold button ortype ctrl-b

    Note: Afterbeing bolded,

    the wordEmployee isnow too widefor the column,so make thecolumn widerif necessary(this step is notshown).

    39

  • 7/31/2019 Excel Final UPES

    38/259

    Format Cells Using the formatting buttons only

    give you a limited amount of

    formatting ability. For more formatting ability, select

    one or more cells and right clickon the selection. Then chooseformat cells from the popup

    menu. Choose options from the Number,

    Alignment, Font, Border andPatterns tabs and press OK tochange the way your informationlooks on the screen.

    The Protection tab is used to lockcells so that their contents cant bemodified.

    We will not go into the details ofusing the format cells dialog box at

    this time but you should be able tofigure out most of it by yourself.

    40

    Formatting changes how things LOOK

  • 7/31/2019 Excel Final UPES

    39/259

    Formatting changes how things LOOK,not how they WORK.

    When you change the format of a cell, Excel stillremembers the original value.

    Excel will use the un-formatted value when

    calculating formula values. Example: if you change numbers to appear with

    fewer decimal points the original number with

    all of its decimal points are used in calculations.

  • 7/31/2019 Excel Final UPES

    40/259

    Formulas

    41

    42

  • 7/31/2019 Excel Final UPES

    41/259

    Excel Formulas

    You must have an equals sign ( = ) as the firstcharacter in a cell that contains a formula.

    The = sign tells excel that the contents of the

    cell is a formula Without the = sign, the formula will not

    calculate anything. It will simply display the

    text of the formula.

    43

  • 7/31/2019 Excel Final UPES

    42/259

    Formulas - correct

    formula with = sign After pressing ENTER

    44

  • 7/31/2019 Excel Final UPES

    43/259

    Missing = sign

    Missing = sign!

    Before pressing enter

    After pressing ENTER

    (no change - not a function)

    45

  • 7/31/2019 Excel Final UPES

    44/259

    Types of operations

    You can use any of the following operations in aformula:operation symbol example

    addition: + =a1+3subtraction: - =100-b3

    multiplication: * =a1*b1

    division: / =d1/100exponentiation ^ =a2^2

    negation - =-a2+3(same symbol as subraction)

    46

    Explicit (literal) values and cell

  • 7/31/2019 Excel Final UPES

    45/259

    Explicit (literal) values and cellreferences

    You can use both explicit values and cellreferences in a formula

    An explicit value is also called a literal value

    Formula with only cell references: =a1*b1

    Formula with only literal values:

    =100/27

    Formula with both cell references and literal values:

    =a1/100

  • 7/31/2019 Excel Final UPES

    46/259

    47

    Errors in Formulas

    48

  • 7/31/2019 Excel Final UPES

    47/259

    Common Errors

    The following are some errors that may appear in a spreadsheet (there are otherstoo).

    ####### Cell is too narrow to display the results of the formula. To fix this simply make the column wider

    and the real value will be displayed instead of the ###### signs. Note that even when the###### signs are being displayed, Excel still uses the real value to calculate formulas thatreference this cell.

    #NAME? You used a cell reference in the formula that is not formed correctly (e.g. =BB+10 instead of

    =B3+10)

    #VALUE! Usually the result of trying to do math with a textual value. Example: =A1*3 where A1 contains the

    word hello

    #DIV/0! Trying to divide by zero. Example: =3/A1 where A1 contains 0 (zero)

    Circular Reference Using a formula that contains a reference to the cell that the formula lives in. Example: putting

    the formula =A1+1 in cell A1 or putting the formula =SUM(A1:B2) in any of the cells A1, B1, A2, B2

  • 7/31/2019 Excel Final UPES

    48/259

    49

    Order of Operations

    50

  • 7/31/2019 Excel Final UPES

    49/259

    Complex formulas

    You can use several operations in one function You can group those operations with parentheses

    Examples

    =3*2+1

    =c1*(a1+b1)

    =(100*a2-10)+(200*b3-20)+30

    =(3+2*(50/b3+3)/7)*(3+b7)

    51

  • 7/31/2019 Excel Final UPES

    50/259

    Order of operations

    When using several operations in one formula,Excel follows the order of operations for math.

    first: all parentheses - innermost first

    second: exponents (^) third: all multiplication (*) and division (/).

    Dothese starting with the leftmost * or /and work to the right.

    fourth: all addition (+) and subtraction (-). Dothese starting with the leftmost + or -

    and work to the right.

    52

  • 7/31/2019 Excel Final UPES

    51/259

    Order of operations

    The value of

    3 + 2 * 5

    is

    13

    NOT 25!

    53

    O d f ti

  • 7/31/2019 Excel Final UPES

    52/259

    Order of operations3 + (100 - 20) / 10 - 6 * 2 / 4 + 9

    3 + 80 / 10 - 6 * 2 / 4 + 9

    3 + 8 - 6 * 2 / 4 + 9

    3 + 8 - 12 / 4 + 9

    3 + 8 - 3 + 9

    11 - 3 + 9

    8 + 9

    answer: 17

    54

  • 7/31/2019 Excel Final UPES

    53/259

    Functions

    55

    h f

  • 7/31/2019 Excel Final UPES

    54/259

    What is a function?

    A function is a "named operation" Functions have

    a name

    parentheses

    parameters/arguments inside the parentheses

    The words parameter and argument mean the same thing

    you can have many parameters for one functionseparated with commas (,)

    The number of parameters is one more than the numberof commas.

    56

    h S f i

  • 7/31/2019 Excel Final UPES

    55/259

    The SUM function

    Examples

    Function Result

    =SUM(1,2,3,4,5) 15

    =SUM(a1,b1,c1) a1+b1+c1

    =SUM(9,a1,b2,5,c1) 9+a1+b2+5+c1

    57

    T i l

  • 7/31/2019 Excel Final UPES

    56/259

    TerminologySUM(1,2,3,4,5)

    The name of the function is "SUM"

    The parameters or argumentsto this function are

    1,2,3,4 and 5

    The entire thing, i.e. SUM(1,2,3,4,5), is a functioncall

    The value of this function call is 15.Another way to say this is that this function callreturns15.

  • 7/31/2019 Excel Final UPES

    57/259

    Ranges (e.g. a1:c3)

    58

    Ranges59

  • 7/31/2019 Excel Final UPES

    58/259

    Ranges A rectangular box of cells is called a range.

    The name of a range is

    the name of the upper left cell of the range

    Followed by a colon :

    Followed by the lower right cell of the range

    Example: A1:B2 is shorthand for A1,A2,B1,B2

    See next slide for more examples

    A1:B2

    Examples of Range Names60

  • 7/31/2019 Excel Final UPES

    59/259

    Examples of Range Names Examples

    C3:E10

    B2:B5

    B3:E3

    61

    U i

  • 7/31/2019 Excel Final UPES

    60/259

    Using a range as a parameter

    Ranges can be specified as a parameters to a functioncall.

    Both of the following function calls produce the sameresult as =a1+b1+c1+a2+b2+c2+a3+b3+c3+a4+b4+c4however the 2nd version uses a range and is muchshorter.

    without a range=SUM(a1,b1,c1,a2,b2,c2,a3,b3,c3,a4,b4,c4)

    with a range

    =SUM(a1:c4)

    62

    Function calls with multiple

  • 7/31/2019 Excel Final UPES

    61/259

    Function calls with multipleparameters

    You can include multiple ranges and cells asparameters

    Example: the following function call has 3 parameters.There are two ranges (a1:b2 and c4:c7), one number(100) and one cell reference (d3)

    =SUM(a1:b2,100,c4:c7,d3)

    Is the same as:

    =SUM(a1,a2,b1,b2,100,c4,c5,c6,c7,d3)

  • 7/31/2019 Excel Final UPES

    62/259

    Other Functions

    63

    64

    Oth f ti

  • 7/31/2019 Excel Final UPES

    63/259

    Other functions

    Click the function button to see the availablefunctions:

    Function buton

    brings up the

    function dialog box

    (see next slide)

    65

    E l

  • 7/31/2019 Excel Final UPES

    64/259

    Example

    AVERAGE

    formula that contains a function value

    =AVERAGE(2,4,10,4) 5

    =AVERAGE(a1,f32) (a1+f32) / 2

    =AVERAGE(a1:c1) (a1+b1+c1) / 3

    =AVERAGE(a1:c1,10) (a1+b1+c1+10) / 4

    66

  • 7/31/2019 Excel Final UPES

    65/259

    Combining Functions and other

    values in a single formula

    67

    F ti d th l

  • 7/31/2019 Excel Final UPES

    66/259

    Functions and other values

    You can combine functions, cell references andliteral values to make a complex Excel formula

    Examples

    =3 + b23 * SUM(d20:g20)=SUM(a1,100) * AVERAGE(d10:j10)

    =100 / ( AVERAGE(b2,c2,d30) + AVERAGE(f1:f20) )

    68

  • 7/31/2019 Excel Final UPES

    67/259

    Other Types of Cell References

    References to entire ROWsReferences to entire COLUMNs

    References to cells or ranges on other worksheets (i.e. tabs)

    69

    E ti R ( )

  • 7/31/2019 Excel Final UPES

    68/259

    Entire Rows (e.g. 2:2 or 2:4)

    A cell reference of the form : refers tothe range of all the cells for those rows.

    Example: The reference, 2:2, refers to all of the cells on the 2ndrow.

    The following formula adds up all of the values on the 2nd and 4throws ofthe spreadsheet:

    =sum(2:2,4:4)

    Another Example: The reference, 2:4, refers to all of the cells on the 2nd , 3rd and 4throws,.

    The following formula adds up all of the values on the 2nd, 3rd, 4th , 10th,11th , 12th, 13th, 14th and 15throws of the spreadsheet:

    =sum(2:4,10:15)

    70

    E ti C l ( B B B D)

  • 7/31/2019 Excel Final UPES

    69/259

    Entire Columns (e.g. B:B or B:D)

    A cell reference of the form : refers to therange of all the cells for those columns.

    Example: The reference, B:B, refers to all of the cells in the 2ndcolumn.

    The following formula adds up all of the values in the 2nd and 4thcolumns of the spreadsheet:

    =sum(B:B,D:D)

    Another Example: The reference, B:D, refers to all of the cells in the 2nd, 3rd and 4thcolumns.

    The following formula adds up all of the values in the 2nd, 3rd, 4th, 6th and7thcolumns of the spreadsheet:

    =sum(B:D,F:G)

    71

    References to cells on other

  • 7/31/2019 Excel Final UPES

    70/259

    worksheets

    Cell on another sheet: sheetName!cellReference Range on another sheet: sheetName!range Row on another sheet: sheetName!row:row Column on another sheet: sheetName!column:column

    If a sheet name has a space in it, you mustsurround the sheet name with apostrophes (i.e.single quotes)

    Examplessheet2!a1sheet2!b4:c8'2002 Forecasts'!f3:f10=sum('2002 Forecasts'!f3:f10)

    =sum('2202 Forecasts'!f:f)

    72

    More examples

  • 7/31/2019 Excel Final UPES

    71/259

    More examples

    Add up values from 2 different sheets=sum ( 'great stocks'!b2:c4, 'so so stocks'!b2:c4)

    This next one is a little confusing

    =sum (a1,a!a1,b1:b4,b1!b4,c!c:c)

    Explanationa1 this is a cell reference on the current sheet

    a!a1 "a" is the name of sheet. "a1" is a cell on the "a" sheetb1:b4 this is a range on the current sheetb1!b4 "b1" is the name of a sheet. "b4" is a cell on the "b1"

    sheetc!c:c c" is the name of a sheet. c:c" is all of the cells in the ccolumn

    on the c sheet

    73

  • 7/31/2019 Excel Final UPES

    72/259

    Absolute and Relative

    Cell References

    74

    Absolute and Relative Cell

  • 7/31/2019 Excel Final UPES

    73/259

    References

    By default, when you copy a formula thatcontains a cell reference, excel willautomatically adjust the cell reference.

    You can stop Excel from automatically adjustingthe cell reference by using one or more dollarsigns ($) in the cell reference. These are called

    absolute cell references.

    A cell reference without a dollar sign is a

    relative cell reference.

    75

    Examples

  • 7/31/2019 Excel Final UPES

    74/259

    Examples

    The following all refer to the same celld9

    $d$9

    $d9

    d$9

    The only difference between these cellreferences relates to what happens when you

    copy a formula that contains the cell reference.

    76

    Relative Cell Reference

  • 7/31/2019 Excel Final UPES

    75/259

    Relative Cell Reference

    d9 This is a "relative cell reference". Changing the column: If I copy this cell reference to another

    cell:

    the "d" will increment one letter for every cell that I

    move over to the right. The "d" will decrement one letter for every cell that I

    move over to the left

    Changing the row: If I copy this cell reference to another cell:

    the "9" will increment by one for every cell that I movedown.

    The "9" will decrement by one for every cell that I moveup

    77

    Absolute cell reference

  • 7/31/2019 Excel Final UPES

    76/259

    Absolute cell reference

    $d$9 This is an absolute cell reference. If I copy a formula with this cell reference, the cell

    reference will NOT change AT ALL.

    78

    Mixed References

  • 7/31/2019 Excel Final UPES

    77/259

    Mixed References

    $d9 and d$9 These are "Mixed" cellreferences:

    $d9 The "d" will stay the same when you copy the cell,

    but the "9" will change.

    d$9

    The "d" will change when you copy the cell, but the"9" will stay the same.

    79

  • 7/31/2019 Excel Final UPES

    78/259

    Data Types

    80

    Data Types

  • 7/31/2019 Excel Final UPES

    79/259

    Data Types Numeric

    values: any number

    operators: + - * / ^ % sample functions: sum( ), average( ), max( ), min( ) etc.

    Text (AKA Character or String)

    values: Any group of letters or numbers or special characters.Prefix value in cell with an apostrophe ( ' ) to force a text value

    operators: & (concatenation) sample functions: right( ), left(), mid(), lower(), upper(), len(), etc

    Dates

    values: dates and timesoperators: N/A

    sample functions: now( ), today( ), hour(), minute(), etc.

    Logical (AKA boolean)

    values: true false

    Operators: < > = =

    sample functions: if( ), and( ), or( ), not( ), isblank()

    81

    Data Types for Values in Cells

  • 7/31/2019 Excel Final UPES

    80/259

    Data Types for Values in Cells

    By default: a cell that contains a number is treated as numeric

    data

    a cell that contains a date is treated as date data(we'll see more about this later)

    a cell that contains data which isnot numeric and not a date is treated as "text"

  • 7/31/2019 Excel Final UPES

    81/259

    82

    Text Data

    83

    Text / String / Character

  • 7/31/2019 Excel Final UPES

    82/259

    Text / String / Character

    The following three terms all used to refer to"text" data. All three terms mean the samething.

    text data

    string data

    character data

    This presentation will generally use the term"text data" but you should be familiar with the

    terms "string data" and "character data" 84

    Text data

  • 7/31/2019 Excel Final UPES

    83/259

    Text data

    Text data is used to store general purpose text(e.g. names, places, descriptions, etc)

    You can't do "math" with text values(obviously)

    85

    Text isn't part of numerical calculations

  • 7/31/2019 Excel Final UPES

    84/259

    (obviously)Formula to

    add up all

    numbers in

    column C

    (Same

    Spreadsheet)

    Text data inC1 is not

    included in

    the Sum

    formula view (press Cntrl-`)

    values view (press Cntrl-`)

  • 7/31/2019 Excel Final UPES

    85/259

    86

    Text Functions

    87

    Text Functions

  • 7/31/2019 Excel Final UPES

    86/259

    Text Functions

    Many functions are used to manipulate textvalues.

    The following are only some of them

    right( )left( )mid( )concatenate( )

    lower( )upper( )len( )

  • 7/31/2019 Excel Final UPES

    87/259

    88

    RIGHT, LEFT and MID functions

    89

    RIGHT function

  • 7/31/2019 Excel Final UPES

    88/259

    RIGHT function

    The RIGHT function is used to isolate a specificnumber of characters from the right hand sideof a text value.

    (example on next slide)

    90

    RIGHT ( )

  • 7/31/2019 Excel Final UPES

    89/259

    RIGHT ( , )

    Formula View

    Values View

    91

    RIGHT numCharacters is optional

  • 7/31/2019 Excel Final UPES

    90/259

    RIGHT numCharacters is optional

    The parameter in the RIGHTfunction is optional. If you dont specify it thedefault is 1 (one).

    Formula View

    Values View

    These produce thesame results.

    92

    LEFT

  • 7/31/2019 Excel Final UPES

    91/259

    LEFT

    The LEFT function is the same as the RIGHTfunction, but it returns characters from theLEFT side of the value.

    93

    MID ( , ,Ch )

  • 7/31/2019 Excel Final UPES

    92/259

    )

    MID is used to get values from the middle ofsome text.

    MID takes 3 parameters: The original text

    The position to start taking the new value from

    The number of characters to take for the new value

    Example on next slide

    94

    Example: MID ( , ,Ch )

  • 7/31/2019 Excel Final UPES

    93/259

    )

    This example extracts the second through thefourth characters from the original text value:

    Formula View

    Values View

  • 7/31/2019 Excel Final UPES

    94/259

    95

    Concatenation( & ) and

    CONCATENATE function

    96

    Concatenation (&)

  • 7/31/2019 Excel Final UPES

    95/259

    Concatenation (&)

    Use & to combine (or concatenate) two different text values

    Formula View

    Values View

    Notice that there is no

    space between the two

    values

    97

    Concatenate many values

  • 7/31/2019 Excel Final UPES

    96/259

    Concatenate many values

    You may concatenate many values togetherFormula View

    Values View

    98

    Concatenation with "literal" values

  • 7/31/2019 Excel Final UPES

    97/259

    Concatenation with literal values

    You can also concatenate "literal" values. You must include the literal values inside quotes

    For example to display spaces in the "full name" in theprevious example you could use the following formula.Each space that you want to display must be includedin quotes.

    =A2&" "&B2&" "&C2(Don't forget any of the &'s )

    99

    Concatenating spaces - Example

  • 7/31/2019 Excel Final UPES

    98/259

    Concatenating spaces Example

    You can concatenate spaces into a formulaFormula View

    Values View valuescontainspaces

    100

    LEFT( ) with & in same formula

  • 7/31/2019 Excel Final UPES

    99/259

    LEFT( ) with & in same formula You can combine the results of different

    function calls with concatenation.Formula View

    Values View

    101

    Putting it all together

  • 7/31/2019 Excel Final UPES

    100/259

    g g In this example we concatenate periods into the

    initials.Formula View

    Values View

    The initials now contain

    periods

    102

    Separate first name & Last NameU f S h & L ft f ti

  • 7/31/2019 Excel Final UPES

    101/259

    - Use of Search & Left function

    Formula View

    Values View

    103

    CONCATENATE Function

  • 7/31/2019 Excel Final UPES

    102/259

    You can use the CONCATENATE functioninstead of the ampersand (&).

    The following formulas are equivalent:

    =A1&B1&C1

    =CONCATENATE(A1,B1,C1)

    The CONCATENATE function can take as many

    parameters as you like

  • 7/31/2019 Excel Final UPES

    103/259

    104

    More Text Functions:PROPERLOWER

    UPPERLEN

    105

    LOWER ( )UPPER ( t tV l )

  • 7/31/2019 Excel Final UPES

    104/259

    UPPER ( )

    LOWER converts text to lower case. UPPER converts text to upper case.

    PROPER Coverts first letter in upper Case

    Example:Formula View

    Values View

    106

    LEN ( )

  • 7/31/2019 Excel Final UPES

    105/259

    ( )

    LEN returns a numeric value equal to thenumber of character in a text value (i.e. thelength of the text value).

    Spaces ARE included in the length. Example

    Formula View

    Values View

    107

    TRIM ( )

  • 7/31/2019 Excel Final UPES

    106/259

    ( )

    Formula View

    Values View

    108

    REPT ( |,Cell Ref )

  • 7/31/2019 Excel Final UPES

    107/259

    ( | , )

    Formula View

    Values View

  • 7/31/2019 Excel Final UPES

    108/259

    109

    Dates and Times

    110

    How Excel Stores Dates

  • 7/31/2019 Excel Final UPES

    109/259

    Dates are stored in Excel as the number of days since Dec 31,1899 for that date. (ex. Jan 1, 1900 is stored as the number 1).

    To see this, type a date in a cell and then press Ctrl-` to see theformulas view.

    Example Values View

    Formulas View

    Dates become

    numbers in

    formulas

    view

    111

    Times and Dates in the same Cell

  • 7/31/2019 Excel Final UPES

    110/259

    A cell can contain both a date and a time.

    The value of both the date and the time is stored internally as a single decimalnumber.

    The whole number portion represents the DATE and is the number of days since Dec.31, 1899

    The decimal part represents the TIME and is the fraction of the day that has elapsed.

    Examples:

    Jan 1, 1900 at 12AM is 1.0 (i.e. 1 day since Dec 31, 1899 and 0 percent of the day elapsed sofar)

    Jan 1, 1900 at 12PM is 1.5 (i.e. 0.5 of the day elapsed)

    Jan 2, 1900 at 12PM is 2.5 (i.e. 2 days since Dec. 31, 1899)

    Feb 1, 1900 at 1:05 PM is 32.5451388888889 (i.e. 32 days since Dec 31, 1899 and0.5451388888889 of the day elapsed by 1:05 PM. This makes sense as it is a little pastnoon so a little more than half of the day elapsed.

    112

    Times and Dates - Example

  • 7/31/2019 Excel Final UPES

    111/259

    p

    Values View

    Formulas View

    113

    Date Arithmetic

  • 7/31/2019 Excel Final UPES

    112/259

    You can do arithmetic with dates. Add and subtract days by adding and subtracting whole

    numbers. Add and subtract times by adding and subtracting fractional

    values.

    Examples=A1+7 (one week after the date in A1)

    =A1-5*7 (5 weeks before the date in A1)

    =A1- (1/24) (one hour before the time specified in A1)

    =A1+ (3/24) (three hours after the time specified in A1)

    =A1+2.5 (two and a half days after the time specified in A1)

    =A1-A2+1 (the # of days between the date in A1 and the date in A2)

    114

    Formatting cells with Dates andTimes

  • 7/31/2019 Excel Final UPES

    113/259

    Times

    Right click on the cell andchoose Format Cells

    From the Category list inthe Number tab either

    Choose Date, Time orCustom and choose anappropriate looking format

    OR

    If you choose General orNumber, the internal numberfor the Date/Time will bedisplayed in the spreadsheeteven in the values view.

    115

    Date & Time Functions

  • 7/31/2019 Excel Final UPES

    114/259

    Current Date - TODAY( ) Current Time Now ( )

    Year ( )

    Month ( )

    Day ( )

    116

    Date & Time Functions

  • 7/31/2019 Excel Final UPES

    115/259

    Add months to start dates by : EDATE (startdate, months)

    Extract age of person by DATEDIF (Start

    date, end date, format) Format :

    Y for difference in years

    M for difference in months

    D for difference in Days

    YM for difference in Months ignoring years

    YD for difference in Days ignoring years

    MD for difference in Days ignoring Month & years

    117

    Date & Time Functions

  • 7/31/2019 Excel Final UPES

    116/259

    Formula View

    Values View

  • 7/31/2019 Excel Final UPES

    117/259

    118

    Logical values

    119

    Logical operators

  • 7/31/2019 Excel Final UPES

    118/259

    In Excel the following "operators" are usedOperator Meaning

    > greater than< less than>= greater than or equal to 2 true

    3 < 2 false

    120

    Logical Formulas

  • 7/31/2019 Excel Final UPES

    119/259

    Formula View Values View

    121

    Same formulas, different values

  • 7/31/2019 Excel Final UPES

    120/259

    Formula View Values View

    122

    IF function

  • 7/31/2019 Excel Final UPES

    121/259

    Formula View Values View

    123

    IF with a numerical result

  • 7/31/2019 Excel Final UPES

    122/259

    Formula View Values View

    124

  • 7/31/2019 Excel Final UPES

    123/259

    AND

    OR

    NOT

    125

    AND

  • 7/31/2019 Excel Final UPES

    124/259

    The following is TRUE

    Fish live in water AND deer live on land.

    The following are all FALSE

    Fish live in water AND deer live in water.

    Fish live on land AND deer live on land.Fish live on land AND deer live in water.

    126

    AND function

  • 7/31/2019 Excel Final UPES

    125/259

    127

    AND

  • 7/31/2019 Excel Final UPES

    126/259

    Formula View Values View

    128

    IF with AND - nested function calls

  • 7/31/2019 Excel Final UPES

    127/259

    You can use an AND inside of an IF. This is called a NESTED FUNCTION CALL

    Example

    =IF( AND (A2>A3,B2B3) , 500, 1000)

    AND is "nested" inside of the IF

    These parentheses "belong to" the if

    129

    IF with AND - parameters

  • 7/31/2019 Excel Final UPES

    128/259

    Parameters for IF function:

    130

    IF with AND - spreadsheet views

  • 7/31/2019 Excel Final UPES

    129/259

    Formula View Values View

    131

    AND function

  • 7/31/2019 Excel Final UPES

    130/259

    Takes any number of parameters Returns TRUE if ALL of the parameters evaluate

    to TRUE otherwise returns FALSE.

    132

    OR and NOT functions

  • 7/31/2019 Excel Final UPES

    131/259

    133

    OR

  • 7/31/2019 Excel Final UPES

    132/259

    Takes any number of parameters Returns TRUE if ANY of the parameters

    evaluate to TRUE otherwise returns FALSE

    134

    NOT

  • 7/31/2019 Excel Final UPES

    133/259

    Takes ONLY ONE parameter Returns the "opposite" of the value of the

    parameter

    returns FALSE if the parameter value is TRUE returns TRUE if the parameter value is FALSE

    135

    Examples of Complex Nested Function Calls

  • 7/31/2019 Excel Final UPES

    134/259

    =IF(AND(A2>A3, OR(B2=B3,C2A3, OR(B2=B3,C2A3, NOT(OR(B2=B3,C2

  • 7/31/2019 Excel Final UPES

    135/259

    136

    Other Logical Functions:ISBLANK

    137

    ISBLANK( ) ISBLANK returns TRUE if the value is blank and

  • 7/31/2019 Excel Final UPES

    136/259

    false otherwise. (see example below)

    Formula View

    Values Viewblank value

    Total will be

    wrong if

    quantity is

    blank (since

    a blank is

    normally

    treated as

    zero)

    Total will be correct even if quantity

    is blank (quantity is assumed to be 1

    in that case)

  • 7/31/2019 Excel Final UPES

    137/259

    138

    FORMATTING A CELL AS TEXT

    139

    Numbers with leading zeros Sometimes you desire to have to have zeroes displayed at the beginning of a number

  • 7/31/2019 Excel Final UPES

    138/259

    Sometimes you desire to have to have zeroes displayed at the beginning of a number.

    For example, US social security numbers are made up of 9 digits. The first few digitsmay be zeroes.

    This causes in a problem in Excel. When you type in a number with leading zeroesinto a cell, Excel removes the leading zeroes when you press Enter.

    EXAMPLE:If you type the following into a cell (before you press Enter)

    When you press Enter you get this:

    See next slides for how to fix this

    Leadingzeroes aremissing

    140

    Formatting a cell to display as text

  • 7/31/2019 Excel Final UPES

    139/259

    To fix this problem you can format the cell todisplay as text instead of as a number.

    The value will still be able to be used incalculations but it will be displayed on the

    screen using the rules for text values instead ofthe rules to display numbers

    One of the rules Excel uses to displaying

    numbers is to remove leading zeroes. However, if a number displayed as "text" data

    then Excel WILL display leading zeros.

    See next slide for instructions on how to do this 141

    Opening the "Format cells" dialogbox

  • 7/31/2019 Excel Final UPES

    140/259

    Select the cell or cells that you want to format as text. Right click on the selected cell(s) and choose the

    following from the popup menuformat cells

    or click on a cell and choose the following menu choice

    format | cells

    Then you will see the "Format Cells" dialog box.(See the next slide ...)

    142

    "Format Cells" dialog box

  • 7/31/2019 Excel Final UPES

    141/259

    Choose"Text"fromthe"Number" taband

    pressthe OKbutton.

    143

    Not a Perfect Solution

  • 7/31/2019 Excel Final UPES

    142/259

    When you format the cell as text it willdisplay the leading zeroes (you must type themin again).

    However, Excel will warn you that a number isformatted as text.

    144

    Result of Formatting a Number asText

  • 7/31/2019 Excel Final UPES

    143/259

    Excel indicates this issue

    with agreen triangle in the upperleft hand corner of the cell:

    If you select the cell you

    can see the error message.

    You can have Excel toignore this type of errorby choosing the Tools |

    Options menu choice andunchecking the Numberstored as text option fromthe Error Checking tab.(this solution is not shownon this slide)

    Create validation rules for data entry

  • 7/31/2019 Excel Final UPES

    144/259

    You will want to prevent errors in your workbooks asmuch as possible. You can specify the type of data that is allowed and/or a

    range of acceptable values If a value is entered that does not meet the requirements,

    an error message is displayed Setting a rule like this is a preventative measure thatallows you to validate data upon entry

    There are several different options in the DataValidation dialog box allowing you to provide various

    rules related to data entry. You can also provide an input message that will aid the

    user in entering the data.

    The Data Validation dialog boxM B D \ D V lid i

  • 7/31/2019 Excel Final UPES

    145/259

    Menu Bar: Data \ Data Validation

    The Allow list box options

  • 7/31/2019 Excel Final UPES

    146/259

    The Input Message tab of the DataValidation dialog box

  • 7/31/2019 Excel Final UPES

    147/259

    g

    A worksheet with aninput message displayed

  • 7/31/2019 Excel Final UPES

    148/259

    p g p y

    The Error Alert tab of the DataValidation dialog box

  • 7/31/2019 Excel Final UPES

    149/259

    g

    Functions within functions

  • 7/31/2019 Excel Final UPES

    150/259

    You can use functions within functions.Consider the expression=ROUND(AVERAGE(A1:A100),1).

    This expression would first compute the average ofall the values from cell A1 through A100 and thenround that result to 1 digit to the right of thedecimal point

    Circular referenceSituation when some parameter in the formula refers

  • 7/31/2019 Excel Final UPES

    151/259

    Situation when some parameter in the formula refersto the formula itself

    For example, in cell C5 the following formula is entered:

    VLOOKUP(C5, F2:G15, 2, TRUE)

    The address C5 refers to the formula itself.In this case it is a wrong way of writing the formula.

    In some cases circular references may be usedfor creating recursive (recurrent) functions.

  • 7/31/2019 Excel Final UPES

    152/259

    Tables, Graphs and

    ExcelSolving Problems Using

    Graphical Analysis

    Tables

  • 7/31/2019 Excel Final UPES

    153/259

    Tables should always have: Title

    Column headings with brief descriptive name, symbol andappropriate units.

    Numerical data in the table should be written to theproper number of significant digits. The decimal points in a column should be aligned.

    Tables should always be referenced and discussed (atleast briefly) in the body of the text of the documentcontaining the table.

    Graphs

  • 7/31/2019 Excel Final UPES

    154/259

    Proper graphing of data involves several steps: Select appropriate graph type

    Select scale and gradation of axes, and completelylabel axes

    Plot data points, then plot or fit curves

    Add titles, notes, and or legend

  • 7/31/2019 Excel Final UPES

    155/259

    Graphs - Types

  • 7/31/2019 Excel Final UPES

    156/259

    4. Line Graph

    0

    2

    4

    6

    8

    10

    12

    14

    16

    0 500 1000 1500Height (m)

    Temperature(C)

    0

    20

    40

    60

    80

    100

    120

    140

    160

    Pressure(kPa)

    Temp

    Pressure

    12

    3

    4

    5

    6

    7

    0123456

    78

    0246

    8101214

    Object 1Object 2

    3. 3-D Graph

    Graphs

  • 7/31/2019 Excel Final UPES

    157/259

    Each graph must include: A descriptive title which provides a clear and concise

    statement of the information being presented

    A legend defining point symbols or line types used forcurves needs to be included

    Labeled axes

    Graphs should always be referenced/discussed in thebody of the text of the document containing the table.

    Titles and Legends

  • 7/31/2019 Excel Final UPES

    158/259

    Each graph must be identified with adescriptive title

    The title should include clear and concisestatement of the information being presented

    A legend defining point symbols or line typesused for curves needs to be included

    Axis Labels

  • 7/31/2019 Excel Final UPES

    159/259

    Each axis must be labeled The axis label should contain the name of the

    variable and its units.

    The units can be enclosed in parentheses, orseparated from the label by a comma.

    Length (km)

    Gradation

  • 7/31/2019 Excel Final UPES

    160/259

    Scale gradations should be selected so that thesmallest division of the axis is an integer powerof 10 times 1, 2, or 5.

    Exception is units of time.

    0 10 20 30

    Scale Graduations,Smallest Division=1

    Acceptable

    0 10 20 30

    Scale Graduations,Smallest Division=3.33

    Not Acceptable

    Data Points and Curves

  • 7/31/2019 Excel Final UPES

    161/259

    Data Points are plotted using symbols The symbol size must be large enough to easily

    distinguish them

    A different symbol is used for each data set

    Data Points are often connected with lines

    A different line style is often used for each data set

    Example

  • 7/31/2019 Excel Final UPES

    162/259

    Distance (Km)

    0 1 2 3 4 5

    Velocity(m/s)

    0

    1

    2

    3

    4

    5

    6

    7

    8

    9

    10

    Runner #1

    Runner # 2

    Runner # 3

    Velocity of Three RunnersDuring a 5 km Race

    Building a Graph In Excel

  • 7/31/2019 Excel Final UPES

    163/259

    Select the data that you want to include in the chart bydragging through it with the mouse.

    Then click the Chart Wizard

    Building the Graph

  • 7/31/2019 Excel Final UPES

    164/259

    Choose XY(Scatter), with

    data connectedby lines ifdesired.

    Click Next

    Building the Graph

  • 7/31/2019 Excel Final UPES

    165/259

    Make sure that theseries is listed incolumns, since your

    data is presented incolumns.

    Click the Series tab to

    enter a name for thedata set, if desired.

    Choose Next

    Building the Graph

  • 7/31/2019 Excel Final UPES

    166/259

    Fill in Title and Axis information

    Next

    Building a Chart

  • 7/31/2019 Excel Final UPES

    167/259

    Select As new sheet to create the chart on itsown sheet in your Excel file, or As object in tocreate the chart on an existing sheet

    Finish

    Creating a Secondary Axis

  • 7/31/2019 Excel Final UPES

    168/259

    This is useful when the data sets cover very differentranges.

    Right click on the line (dataseries) on the chart that you

    want to associate with asecondary axis.

    Select format data series

    Select the Axis tab, then

    Plot series on secondaryaxis as shown.

    OK

    Editing/Adding Labels

  • 7/31/2019 Excel Final UPES

    169/259

    Now you can go back to the chart options to add labels

    Click the chart in a blank area, then either right click andselect chart options or choose chart options from the

    Chart menu

    Fill in or edit theaxes labels, title,etc.

    Click OK

    Result

  • 7/31/2019 Excel Final UPES

    170/259

    Goal Seek

  • 7/31/2019 Excel Final UPES

    171/259

    Goal Seekis an analytical function that allows a valuein a formula to be adjusted to reach a desired result oranswer.

    Goal Seek can eliminate unnecessary calculations thatcan be used to determine a single variable value in aformula.

    For example, a salesperson might participate in abonus program that pays 3 percent of all sales dollars.The salesperson wants to receive a bonus of at least$2,500 and needs to know the target sales dollaramount needed.

  • 7/31/2019 Excel Final UPES

    172/259

    Create a worksheet with the following information

    When the Goal Seek command starts to run, it repeatedly tries new values inthe variable cell to find a solution to the problem.

    This process is called iteration, and it continues until Excel has run theproblem 100 times or has found an answer within .001 of the target valuespecified.

    The iteration settings can be adjusted by choosing Tools, Options, andadjusting the Iteration options in the Calculations tab.

    It calculates so fast, the Goal Seek command can save significant time andeffort over the brute force method of trying one number after another in aformula.

  • 7/31/2019 Excel Final UPES

    173/259

    Goal Seek

    USING THE GOAL SEEKCOMMAND

  • 7/31/2019 Excel Final UPES

    174/259

    The Goal Seek feature is used to fill in the target value of the cell containing theSales Dollaramount.

    The Goal Seek values read Set cell = B3, To value = 2500, By changing cell = $B$1.

    To use the Goal Seek command:1. SelectTools from the main menu, then selectGoal Seek.2. Specify the cell that contains the desired value in the Set cell text box. Type in or

    selectB3.3. Enter the desired value or answer in the To value text box. Type in 2500.4. Enter the cell whose value will be changed in the By changing cell text box. Type in

    or select$B$1.5. The Goal Seek dialog box should look like Figure next slide6. Choose OK.

    a. If a solution is found, the Goal Seek Status dialog box appears.b. The results are shown in Figure T4.6.

    7. Select OK.

    Goal Seek is used to adjust a single variable in a formula. Use the Solver featureto adjust multiple variables in a formula, as described in the next section.

    Goal Seek Worksheet

  • 7/31/2019 Excel Final UPES

    175/259

    Goal Seek Results

  • 7/31/2019 Excel Final UPES

    176/259

  • 7/31/2019 Excel Final UPES

    177/259

    Solver

    Solver Solver is part of a suite of functions sometimes called what-if analysis tools used

    for optimizing problems that contain more than one variable

  • 7/31/2019 Excel Final UPES

    178/259

    for optimizing problems thatcontain more than one variable.

    The Solver add-in utility is needed to analyze the scenarios in decision-makingsituations that involve consideration of values and constraints for several

    variables simultaneously.

    This powerful function uses multiple changing variables and constraints to find

    the optimal solution to solve a problem.

    For example, consider a coffee shop that currently sells three beverages: (1)

    regular fresh-brewed coffee, (2) premium caffe latte, and (3) premium caffe

    mocha.

    The current price for regular coffee is set at $1.25, caffe latte at $2.00, and caffe

    mocha at $2.25, but the revenue potential is uncertain. What special emphasis(or marketing) should be given to each of the beverages to maximize revenue?

    Although the premium coffees bring in more money, their ingredients are more

    expensive and they take more time to make than regular coffee. Making some

    basic calculations by hand is easy, but there needs to be some structure to the

    sales data in a worksheet so that periodic changes can be made and analyzed

    Coffee Sales DataSheet for Solver T4.7

  • 7/31/2019 Excel Final UPES

    179/259

    Solver The first step in using the Solver command is to build a

    Solver friendly worksheet This involves creating a target

  • 7/31/2019 Excel Final UPES

    180/259

    Solver-friendly worksheet. This involves creating a target

    cell to be the goal of your problem For example, a formula that calculates total revenueand assigning one or

    more variable cells that the Solver can change to reach the goal.

    To use Solver, complete the following:1. Set up a worksheet similar to Figure T4.7.

    2. The three variable cells in the worksheet are cells D5, D9, and D13. These arethe cells whose values the Solver needs to determine to maximize the weeklyrevenue.

    3. In the bottom-right corner of the table is a list of constraints to use for

    forecasting.

    4. The worksheet must contain cells (G6 through G8) that include the formulasused as constraints. The limiting values for the constraints are listed in cellsG11 through G13.

    No more than 500 total cups of coffee (both regular and premium).

    No more than 350 cups of premium coffee (both caffe latte and caffe mocha).

    No more than 125 caffe mochas.

    Solver

  • 7/31/2019 Excel Final UPES

    181/259

    5. The subtotals for cells D6, D10, D14 need to be calculated, as well as the Total Revenue (sum of

    D6, D10, and D14) in G4.6. The value for cell G6 should equal the value that will be calculated for D5 and the value for cell

    G7 will be the sum of the values from D9 and D13. The calculation of G8 = SUM of D5, D9, andD13.

    7. Click the target cell G4the one containing the formula that is based on the

    8. variable cells you want the Solver to determine.

    9. Select Tools from the main menu, then select Solver. The Solver Parameters dialog box opens, asshown in Figure T4.8.

    a. Select the Set Target Cell text box (unless it already contains the correct reference), and then click cellG4 to insert $G$4 as the target cell.

    b. The Equal To option button (Max) is already selected. Do not change this since the problem requeststhe maximum value for the target cell.

    10. Select the By Changing Cells text box. Click the button in the text box to collapse the dialog box.

    Select each of the variable cells by holding down the Ctrl key and clicking D5, D9, and D13. Thisplaces commas between the three cell entries in the text box: $D$5, $D$9, $D$13 (refer toFigure T4.9).

    Solver

  • 7/31/2019 Excel Final UPES

    182/259

    11.Click Solve to calculate the result.

    12.Solver displays a dialog box describing the results ofthe analysis. If the Solver runs into a problem, an errormessage will be displayed. If the Solver finds a

    solution, a Solver Results dialog box like Figure T4.11will appear.

    13.To display the new solution in the worksheet, clickthe Keep Solver Solution option button, and then click

    OK. The Solver places an optimum value in the targetcell and fills the variable cells with the solutions thatsatisfy the constraints specified and provide theoptimal result, as shown in Figure T4.12.

    Solver T4.8-T4.11

  • 7/31/2019 Excel Final UPES

    183/259

    Optimum Revenue forSolver Results T4.12

  • 7/31/2019 Excel Final UPES

    184/259

  • 7/31/2019 Excel Final UPES

    185/259

    Pivot Tables

    PIVOT TABLES

  • 7/31/2019 Excel Final UPES

    186/259

    A powerful built-in data-analysis feature inExcel is the PivotTable

    A PivotTable analyzes, summarizes, andmanipulates data in large lists, databases,worksheets, or other collections

    It is called a PivotTable because fields can bemoved within the table to create different typesof summary lists, providing a pivot

    What is an Excel Pivot Table?

    A i i k h bl

  • 7/31/2019 Excel Final UPES

    187/259

    An interactive worksheet table

    Provides a powerful tool for summarizing largeamounts of tabular data

    Similar to a cross-tabulation table

    A pivot table classifies numeric data in a list based onother fields in the list

    General purpose:

    Quickly summarize data from a worksheet or from anexternal source

    Calculate totals, averages, counts, etc. based on anynumeric fields in your table

    Generate charts from your pivot tables

    Pivot Table Advantages

    l h b

  • 7/31/2019 Excel Final UPES

    188/259

    Interactive: easily rearrange them bymoving, adding, or deleting fields

    Dynamic: results are automaticallyrecalculated whenever fields are added ordropped, or whenever categories are hiddenor displayed

    Easy to update: refreshable if the originalworksheet data changes

    Appropriate Data

    D t d i li t

  • 7/31/2019 Excel Final UPES

    189/259

    Data arranged in a list:

    Columns represent fields

    Rows represent a record of related data

    First row = column label

    Columns contain one sort of data For example, text in one column and numeric

    values in a separate column

    Remove subtotals

    You CAN work with subtotals, but use caution

    De-normalized database extracts are great forpivoting!

    Appropriate Data Example

  • 7/31/2019 Excel Final UPES

    190/259

    Incomplete records:First Last Gender Semester Major Credit Hours

    Sandra Archer F Fall 1999 Statistics 15

    Fall 2005 Industrial Engineering 6

    Hamilton Paws M Spring 2003 Philosophy 12

    Summer 2005 Chemistry 12

    First Last Gender Semester Major Credit Hours

    Sandra Archer F Fall 1999 Statistics 15

    Sandra Archer F Fall 2005 Industrial Engineering 6

    Hamilton Paws M Spring 2003 Philosophy 12Hamilton Paws M Summer 2005 Chemistry 12

    Spelledthe same

    Appropriate Data Example

    Mi d l

  • 7/31/2019 Excel Final UPES

    191/259

    Mixed use columns :

    College Department FacultyCreditHours

    Science Statistics Ima Faculty 16

    YTD Expenses: $4,000

    Humanities History Hesa Prof 12

    YTD Expenses: $3,500

    Humanities Art Salvador Dali 24

    YTD Expenses: $2,000

    College Department Faculty

    Credit

    Hours

    YTD

    ExpensesScience Statistics Ima Faculty 16 $4,000

    Humanities History Hesa Prof 12 $3,500

    Humanities Art Salvador Dali 24 $2,000

    ColumnLabel

    Appropriate Data Example

    C l l b l i

  • 7/31/2019 Excel Final UPES

    192/259

    Column label issues:

    College Department Faculty 2004 2005 2006 2004 2005 2006

    Science Statistics Ima Faculty $4,000 $5,000 $6,000 16 19 22

    Humanities History Hesa Prof $3,500 $4,500 $5,500 12 15 18

    Humanities Art Salvador Dali $2,000 $3,000 $0 24 21 0

    YTD Expenses Student Credit Hours

    College Department Faculty

    YTD

    Expense

    2004

    YTD

    Expense

    2005

    YTD

    Expense

    2006

    Student

    Credit

    Hours

    2004

    Student

    Credit

    Hours

    2005

    Student

    Credit

    Hours

    2006

    Science Statistics Ima Faculty $4,000 $5,000 $6,000 16 19 22

    Humanities History Hesa Prof $3,500 $4,500 $5,500 12 15 18Humanities Art Salvador Dali $2,000 $3,000 24 21

    Zero orBlank?

    PivotTable Terminology

    S t bl Pi tT bl t

  • 7/31/2019 Excel Final UPES

    193/259

    Some notable PivotTable terms are:

    Row field - Row fields have a row orientation in aPivotTable report and are displayed as row labels

    Column field - Column fields have a column orientation in aPivotTable report and are displayed as column labels

    Data field - Data fields from a list or table contain summarydata in a PivotTable, such as numeric data (e.g., statistics,sales amounts)

    Page field - Page fields filter out the data for other items anddisplay one page at a time in a PivotTable report

    PivotTable Terminology

  • 7/31/2019 Excel Final UPES

    194/259

    Using the PivotTable Feature

  • 7/31/2019 Excel Final UPES

    195/259

    1. Select the worksheetPivotTableData2. Click any cell in the list

    3. Select Data on the menu bar, then choose

    Pivot-Table and PivotChart Report

    Using the PivotTable Feature

    4 In the Where is the data that you want to

  • 7/31/2019 Excel Final UPES

    196/259

    4. In the Where is the data that you want to

    analyze? area, choose Microsoft Excel listordatabase if it is not already selected

    5. In the What kind of report do you want to

    create? area, choose PivotTable6. Click the Nextbutton

    In the Range box, the range should be$A$1:$D$352

    7. Click the Nextbutton

    8. Click Finish

    9. Select New Worksheet

    Using the PivotTable Feature

  • 7/31/2019 Excel Final UPES

    197/259

    Using the PivotTable Feature

  • 7/31/2019 Excel Final UPES

    198/259

    Drag the Business Segmentbutton to the PageField area

    Drag the Unitbutton to the COLUMN area

    Drag the Particulars button to the ROW area Drag theAmountbutton to the DATA area

    Modifying A PivotTable View

  • 7/31/2019 Excel Final UPES

    199/259

    PivotTable Tools

    PivotTable - Contains commands for working

  • 7/31/2019 Excel Final UPES

    200/259

    PivotTable- Contains commands for workingwith a PivotTable

    Format Report - Enables the user to format thePivotTable report

    Chart Wizard - Enables the user to create achart using the data in the PivotTable

    Hide Detail - Hides the detail information in a

    PivotTable and shows only the totals Show Detail - Shows the detail information in a

    PivotTable

    PivotTable Tools

    Refresh External Data - Allows the user to refresh

  • 7/31/2019 Excel Final UPES

    201/259

    Refresh External Data Allows the user to refresh

    the data in the PivotTable after changes to data aremade in the data source Include Hidden Items in Totals - Lets the user show

    the hidden items in the totals

    Always Display Items - Always shows the field itembuttons with drop-down arrows in the PivotTable Field Settings - Displays the PivotTable Field dialog

    box so that the user can change computations andtheir number format

    Hide Field List - Hides and shows the PivotTable FieldList window

    Building A PivotChart

    A PivotChart is a column chart (by default) that

  • 7/31/2019 Excel Final UPES

    202/259

    A PivotChart is a column chart (by default) thatis based on the data in a PivotTable

    To build a PivotChart:1. Click the Chart Wizard on the PivotTable toolbar

    Excel will automatically create a new worksheet,labeled Chart 1, and display the current PivotTableinformation in chart form

    2. Modifications to the PivotChart can be done by

    selecting the drop-down lists to the right of thefield names

    Building A PivotChart

  • 7/31/2019 Excel Final UPES

    203/259

  • 7/31/2019 Excel Final UPES

    204/259

    Protect Sheet/ Workbook

    Protect the contents of worksheetsand workbooks

    Once you have a worksheet that you know is correct

  • 7/31/2019 Excel Final UPES

    205/259

    Once you have a worksheet that you know is correct,

    you may want to protect the worksheet so that userscannot make changes. Setting the locked property will disallow any changes to a

    particular cell

    The worksheet will have to be protected in order for thelocked property to have any affect

    You can also specify a password that must be enteredin order to remove worksheet protection.

    Finally, you can protect an entire workbook, whichwould disallow changes to the workbook, such asadding or deleting worksheets.

    Unlocking Selected Cells

  • 7/31/2019 Excel Final UPES

    206/259

    The Protect Sheet dialog box

  • 7/31/2019 Excel Final UPES

    207/259

    The Protect Workbook dialog box

  • 7/31/2019 Excel Final UPES

    208/259

  • 7/31/2019 Excel Final UPES

    209/259

    Financial Functions

    Financial Function descriptions

    This chart shows some commonly used financial

    functions and a description of what they do

  • 7/31/2019 Excel Final UPES

    210/259

    functions and a description of what they do.

    Excel's financial functions

    Financial functions are very useful to calculate

  • 7/31/2019 Excel Final UPES

    211/259

    Financial functions are very useful to calculate

    information about loans.

    Common functions are FV, IPMT, PMT, PPMT and PV.

    All these financial functions will use similar argumentsthat differ based upon which function you are using.

    Think of the arguments as members of an equation

    The arguments represent the values of the equation that areknown and the function provides the solution for a singlevariable, or unknown, value

    Use the financial functions The FV function calculates the future value of an investment

    based on periodic, constant payments and a constant interest

  • 7/31/2019 Excel Final UPES

    212/259

    rate per period.

    The IPMT function provides the interest payment portion of theoverall periodic loan payment.

    The PMT function calculates the entire periodic payment of theloan.

    The PPMT function calculates just the principal paymentportion of the overall periodic payment.

    The PV function calculates the present value of an investment.

    Use the financial functions (contd)

    NPER Determines the number of payments

  • 7/31/2019 Excel Final UPES

    213/259

    needed for an Investment to grow or pay back aloan

    RATE Determines the effective interest rate

    Standard arguments

    rate: Interest rate (in decimal) per period

  • 7/31/2019 Excel Final UPES

    214/259

    rate: Interest rate (in decimal) per period

    nper: Number of periods

    pmt: Regular payment

    More standard arguments

    pv: Present value: The amount the

  • 7/31/2019 Excel Final UPES

    215/259

    pv: Present value: The amount theseries of future payments is worthnow. The beginning value.

    fv: Future value: The amount theseries of future payments will beworth in the future. The final value.

    type 0 = payment at end of period (default)1 = payment at beginning

    PMT() Payments

    Returns the periodic payment for an annuity or loan

  • 7/31/2019 Excel Final UPES

    216/259

    p p y y

    PMT(rate, nper, pv, fv, type)

    The first 3 (red) arguments are required

    PMT() Example

  • 7/31/2019 Excel Final UPES

    217/259

    Ms Just Retired has $200,000 to invest at 10%annual interest. Her goal is to have $100,000left after 5 years. If she makes equal

    withdrawals each year for 5 years, how muchcan she withdraw each year?

    PMT(rate, nper, pv, fv, type)= PMT(0.10, 5, -200000, +100000)= $36,380

    PMT() Example

  • 7/31/2019 Excel Final UPES

    218/259

    PV() Present Value

    Returns the present value of an investment.

  • 7/31/2019 Excel Final UPES

    219/259

    Returns the present value of an investment.The present value is the total amount that aseries of future payments is worth now. That is,it is the beginning value of the investment or

    loan.

    PV(rate, nper, pmt, fv, type)

    PV() Example

    A person promises to pay you $200 per month

  • 7/31/2019 Excel Final UPES

    220/259

    A person promises to pay you $200 per monthfor 3 years. If you assume 12% interestcompounded monthly, what is this annuityworth today?

    How much can you borrow at 12% annualinterest compounded monthly and repay in 3years paying $200 per month?

    = -PV(0.12/12, 3*12, 200) = 6021.50

    PV() Example

  • 7/31/2019 Excel Final UPES

    221/259

    FV() Future Value

  • 7/31/2019 Excel Final UPES

    222/259

    Returns the future (final) value of an investment. Thefuture value is the total amount including interest thatseries of payments will be worth.

    How much money will there be in your account if youmake regular payments for a period of time?

    FV(rate, nper, pmt, pv, type)

    FV() Examples

    You will make $200 a month payments into a 12% annual

  • 7/31/2019 Excel Final UPES

    223/259

    interest payable monthly account. How much will you haveafter 3 years?

    = -FV(0.12/12, 3*12, 200) = 8615.38

    You will put $1000 in your account that pays 5% annuallycompounded monthly. You will add $100 to the account everymonth. How much will you have after 10 years?

    = -FV(0.05/12, 10*12, 100, 1000) = 17175.24

    FV() Examples

  • 7/31/2019 Excel Final UPES

    224/259

    IRR() Examples

  • 7/31/2019 Excel Final UPES

    225/259

    IRR() Examples

  • 7/31/2019 Excel Final UPES

    226/259

    NPV() Examples

  • 7/31/2019 Excel Final UPES

    227/259

    SYD() / SLN () Examples

  • 7/31/2019 Excel Final UPES

    228/259

    Formula View

    Value View

  • 7/31/2019 Excel Final UPES

    229/259

    Statistical Functions

    Computing the Mean

    Sum xi divide by n (or N for population mean)

  • 7/31/2019 Excel Final UPES

    230/259

    i y ( p p )

    Excel

    =AVERAGE(cellrange)

    Computing the Mode

    Value that occurs most often in discretized data

  • 7/31/2019 Excel Final UPES

    231/259

    Excel

    =MODE(cellrange)

    Reports first value seen if tie

    Computing the Median

    The middle value in sorted data

  • 7/31/2019 Excel Final UPES

    232/259

    Excel

    =MEDIAN(cellrange)

    Computing the Range

  • 7/31/2019 Excel Final UPES

    233/259

    Range is min to max values Excel

    =MIN(cellrange)

    =MAX(cellrange)

    Computing the Standard Deviation

    Std. Dev. is Square-Root of Variance

  • 7/31/2019 Excel Final UPES

    234/259

    Excel

    =STDEV(cellrange) - sample

    =STDEVP(cellrange) - population

    =VAR(cellrange) - sample

    =VARP(cellrange) - population

    Others Statistical Functions

    Countif ( )

  • 7/31/2019 Excel Final UPES

    235/259

    Countblank ( )

    Subtotal ( )

    Rank ( )

  • 7/31/2019 Excel Final UPES

    236/259

    Mathematical Functions

    Mathematical Functions

    SUMIF ( )

  • 7/31/2019 Excel Final UPES

    237/259

    SUMPRODUCT ( )

    ROUND ( )

    Roundup ( )

    Rounddown ( )

    MROUND ( )

    FLOOR ( )

    POWER ( )

  • 7/31/2019 Excel Final UPES

    238/259

    Correlations

    Correlations

    A quick review:

  • 7/31/2019 Excel Final UPES

    239/259

    Every correlation has a direction (positive ornegative):

    + correlation: high scores on one variable areassociated with high scores on another variable.

    - correlation: high scores on one variable areassociated with lowscores on the other variable.

    Every correlation has magnitude or strength:

    The closer the correlation coefficient is to +1.00 or-1.00, the stronger it is.

    The closer the correlation coefficient is to 0.00, theweaker it is.

    Correlation Practice

  • 7/31/2019 Excel Final UPES

    240/259

    Put the following r values in order fromweakestto strongest:

    -.96 +.05 +.68 -.14 +.70 -.33

    What did you get?

    +.05 -.14 -.33 +.68 +.70 -.96

    * Remember to use absolute values (ignore + or signs)when comparing the strengths of one or more correlationcoefficients. Negative correlation does not mean less thanpositive correlation.

    Correlation Example

  • 7/31/2019 Excel Final UPES

    241/259

    Correlation Example

  • 7/31/2019 Excel Final UPES

    242/259

  • 7/31/2019 Excel Final UPES

    243/259

    Lookup Functions

    Lookup / Reference Functions

    VLOOKUP ( )

  • 7/31/2019 Excel Final UPES

    244/259

    HLOOKUP ( )

    MATCH ( )

    INDEX ( )

    Lookup / Reference Functions

  • 7/31/2019 Excel Final UPES

    245/259

  • 7/31/2019 Excel Final UPES

    246/259

    Conditional Formatting

    Highlight Debt Equity Lower than 0.25 by usingConditional Formatting

  • 7/31/2019 Excel Final UPES

    247/259

  • 7/31/2019 Excel Final UPES

    248/259

    Case Study I

    Prioritization of Projects

    This is a real life case

    Y d h

  • 7/31/2019 Excel Final UPES

    249/259

    You need to prioritize the investment inprojects by working out composite scores

    Parameters for evaluation of Scores for each

    project are: Project IRR

    Debt Equity

    Gestation Period

    Strategic Importance

    Work out the Composite Score for the givenprojects

  • 7/31/2019 Excel Final UPES

    250/259

    Case Study II

    Preparation of Financial Model

    This is the Most Important Case Study for the

    d h d h i i

  • 7/31/2019 Excel Final UPES

    251/259

    students who want to do their career in: Finance

    Business Analyst

    Business Development Dept.

    Project Evaluation

    Risk Estimation

    Preparation of Financial Model

    Prepare following Financial Statement from given case

    d

  • 7/31/2019 Excel Final UPES

    252/259

    study: Project Cash Flow and IRR

    Equity Cash Flow and IRR

    Payback Period (Nominal & Exact)

    Profit & Loss Statement

    Balance sheet

    Interest & Debt Repayment Schedules

    Major Financial Ratios DSCR ROCE

    Profit Margin etc

    Preparation of Financial Model

    Real Life Challenges:

    A h

  • 7/31/2019 Excel Final UPES

    253/259

    Assumptions are changing:

    Model should be sensitive to all the assumptions

    Easy to Understand:

    Model should not be un-necessarily complex Appreciation comes to you if others understands your

    work

    Assumptions sheet should be easily identifiable

    Result should be identified easily

    Model should be checked for accuracy

    Preparation of Financial Model - AssumptionsCapacity of Petrochemical 100000 TonsInitial Price of Polymers 10000 Rs/MT

    Price Escalation 10%

    Variable Cost 30% of Price

    Fixed Cost 30% of Price

  • 7/31/2019 Excel Final UPES

    254/259

    Fixed Cost 30% of PriceCapex of Plant 10,000 Lakhs

    Debt Equity 0.50

    Equity Portion 0.50

    Interest cost 10% Percentage

    Corporate Tax Rate 33% PercentageDividend Payout 20% Percentage

    Dividend Distribution Tax 15% Percentage

    Gestation Period 2.00 Years

    Marotorium Period 2.00 Years

    Repayment 3.00 YearsLoan Tenor 5.00 Years

    Economic Life of Project 4.00 Years

    Project Tenor 6.00 Years

    Discounting Rate 12% Percentage

    Preparation of Financial Statements

    Profit & Loss Statement

    Revenue

    Variable Cost

    Balance Sheet

    Liabilities

    Share Capital

    IDC Calculations

    Capital Cost

    Debt Funding

    Loan Schedule

    Openining Loan

    Addition

  • 7/31/2019 Excel Final UPES

    255/259

    Variable Cost

    Fixed Cost

    Total Expenditures

    Gross Margin (PBDIT)

    Depreciation

    InterestPBT

    Tax

    PAT

    Appropriations

    Dividend

    Dividend Tax

    Reserves

    Share Capital

    Reserves

    Loan

    Total - Liabilities

    Assets

    Gross Block

    Less Depreciation

    Net Block

    CWIP

    Current Asset

    Total - AssetsRecon

    Debt Funding

    Equity Funding

    Total Funding

    Check for Funding

    IDC Funding

    IDC - Debt Funding

    IDC - Equity Funding

    Capex Including IDC

    Debt FundingEquity Funding

    Cumulative Debt Funding

    Cumulative Equity Funding

    Addition

    Repayments

    Closing Loans

    Intrest

    Interest CWIP

    Interest P&L

    Preparation of Financial Statements

    C

  • 7/31/2019 Excel Final UPES

    256/259

    Project Cash Flows

    Outflow

    Inflows

    Net Project Cash flows

    Cumulative Cash FlowsProject IRR

    Payback Period

    Exact Payback Period

    NAV

    Equity Cash Flows

    Outflow

    Inflows

    Net Project Cash flows

    Cumulative Cash FlowsProject IRR

    Payback Period

    Exact Payback Period

    NAV

    Ratio Analysis

    ROCE

    DSCR

    Profit Margin

    Preparation of Financial Model

    N i i

  • 7/31/2019 Excel Final UPES

    257/259

    Now its your timePrepare the Financial Model

    Real World is Complex,Does your model takes care of .Complexities Yes or No Funding Strategy Can change

  • 7/31/2019 Excel Final UPES

    258/259

    Interest Rate Can Change with time Change in Capacity Utilization Capital Expenditure Can vary with inflation

    Economic life of Project may reduce / Expand Project may complete Early or may also delay Addition of Risks Complex Tax calculations

  • 7/31/2019 Excel Final UPES

    259/259

    THANK YOU