Excel Foundation Training (I) ENG
Excel Foundation Training (I) ENG
May 2023
Purpose of this session
Pivot tables
Best practices
Appendixes
References
The primary focus of this course is on foundational Excel skills with some review of
advanced capabilities
Applied Understand how to navigate Manipulate and format text in Mastery chart building (e.g.
Microsoft Excel efficiently Excel dynamic charts with different
Excel Understand Excel shortcut keys Understand advanced Excel but correlated data set with in
Understand standard formulas (e.g. logic) one graph)
formatting principles Perform advanced analytics on Understand how to design
Understand best practices for large data sets macros that increase ease of an
building formulas Understands efficient accuracy Excel model interface
Understand auditing formulas check mechanisms Understand visual basic and
and cell references Perform sensitivity and applicable uses
Convert and manipulate large scenario analysis Mastery of self-referencing
data sets Perform data validation (e.g. in- functions
Basic chart building cell dropdowns ) Understand how to apply
Advanced chart building advanced statistical concepts
Understand purpose of macros using Excel
and uses
4
Functions and Formulas
Functions and Formulas
•In addition to hard coded values, formulas can also reference values in other cells. Simply
type the referenced cell’s column letter and row number when inputting it into a formula
. When you copy a formula that references other cell values, the referenced cells will change
relative to where you move them.
• For example, if a formula references cell A1 and it is moved down two rows and across
two columns, the referenced cell will move down two rows and across three columns to
C3
• You can prevent this by “locking” the column, row, or both with a “$” symbol. By
Hint
default, all cells are set to relative referencing. Placing a $ before a referenced column
or row will make it absolute and lock the value from that column (row)
6
Functions and Formulas
7
Functions and Formulas
A #REF! Error occurs when a cell reference is not valid. Deleting or pasting over cells
referenced by other formulas can cause this type of error. To fix the error:
• To fix the error:
• Select the cell that displays the error
• Press Alt-T, U, E SHORTCUT Press Alt-T, U, E
8
Functions and Formulas
• You will now receive a reference error because that cell no longer exists
9
Functions and Formulas
Allows for a quick glance at values for functions such as sum, count, max, and so on.
• Select the range of data
• Excel displays the range’s specified value on the bottom right-hand corner of the
screen
• Right-click on the value to change the functions
10
Functions and Formulas
We will now build on the basic functions and introduce more advanced functions. Below
is a quick review of the Excel functions you should already know.
Function Description
Sum Sum(number1,[number2],…) – adds together all the numbers in a range of
cells
Min Min(number1,[number2],…) – finds the minimum number in a series of
numbers or range of cells and returns that number
Max Max(number1,[number2],…) - finds the maximum number in a series of
numbers or range of cells and returns that number
Count Count(value1,[value2],…) – counts the total amount of cells containing
numbers in a given range of cells and returns an integer
CountA CountA(value1,[value2],…) – counts the total amount of cells containing text
in a given range and returns an integer
11
Functions and Formulas
Max Min
Definition This function will return the largest value This function will return the smallest
in a selected range of cells value in a selected range of cells
Example Note that Blank cells and Text are not included in the results of these functions
Formula Answer
=max (A1:A4) 30
=max (A1:A4, 100) 100
=max (A1, A3) 30
=max (A1, A5) 10
Formula Answer
=min (A1:A4) 10
=min (A2:A3, 100) 20
=min (A1, A3) 10
12
=min (A1, A5) 10 12
Functions and Formulas
The IF statement
IF Statement
Definition A conditional statement that returns a specified value if the condition you are
testing is true and another value if the condition is false
Interpretation [Logical Test]: If I13 (the cell containing the FY08 Budget) is greater than J13 (the
cell containing the FY08 Spend); [value if true]: enter “Under Budget” into the
cell; [value if false]: if not, enter “Over Budget”
Example Using the Savings Dashboard tab, determine if a given division was Under Budget
or Over Budget for FY08
Equation K13=IF(I13>J13, “Under Budget”, “Over Budget”)
13
Functions and Formulas
14
Functions and Formulas
15
Functions and Formulas
SUMIF Statement
Definition Adds the cells within a given range specified by a specific criteria
Criteria
16
Functions and Formulas
COUNTIF Statement
Definition Counts the number of cells within a range that meet the given criteria
Range
Criteria
17
Functions and Formulas
VLOOKUP
Definition VLOOKUP finds a predetermined value, compares it to the leftmost column in a table,
and returns a value in the same row
Parameters VLOOKUP(lookup_value, table_array, col_index_num, [range_lookup])
When to Use VLOOKUP is an excellent function to use when the user needs to import data from
one table into another using a unique lookup value—or—if the user wants to verify
that data values from a certain table match the data values from another table
Identify a unique lookup value common to each table:
It seems that the field Division is unique and listed in both tables. We will use this
as our lookup value
18
Functions and Formulas
VLOOKUP
Interpretation [lookup value]: The value in the destination table we wish to look up in the source table. We
will use Division number as the Lookup Value
[table array]: This is the table from which we a getting the information (outlined in red
below)
[col index num]: Once Excel has located the lookup value (the purchase number), it needs to
know where the column with the data you wish to return is located, relative to the first
column. We want City, which is two columns to the right of the first column in the table
array, so the column index num is 2 [range lookup]: If you want VLOOKUP to find the exact
value in the table array rather than a range of values, put “FALSE” for the range lookup (you
will use false most of the time)
Lookup Value
Table Array
1 2 3 19
Col_Index_Num
Functions and Formulas
VLOOKUP
Example In our example, we have a tab (Division Information) that lists out all Division
Numbers and the associated City and State. On the Savings Dashboard tab we list
only the Divisions with savings associated with them and need to determine the
City and State
20
Functions and Formulas
VLOOKUP
Equation B13=VLOOKUP(A13,'Division Info'!$A$2:$C$101,2,FALSE)
Source Table Destination Table
Lookup Value
Table
Array
1 2 3
Col_Index_Num
21
Functions and Formulas
• If VLOOKUP does not find the lookup value in the table array, it will return “#N/A”
• Often, if the lookup value is not formatted correctly, VLOOKUP will return “#N/A”
even if the values are the same. Make sure the lookup values in both tables are
formatted the same
• VLOOKUP uses the first column in the table array to find the lookup value. If the
lookup value cannot be found in the first column (i.e., Maybe it is in the second or
third column), change the table array so that the column with the lookup values is
first. If you do not, Excel will return “#N/A.”
• It is helpful to sort the table array before using the VLOOKUP (sort by the column
containing the lookup values)
22
Functions and Formulas
• Transfer all of the City fields down column B. Create a new equation that
Hint
locates the State and fill that down column C
23
Functions and Formulas
•Conditional formatting can be used to locate invalid or incorrect data or to highlight reference cells that
need to be accentuated for presentation purposes. Conditional formatting automatically applies a format,
such as cell shading or font color, to cells if a specified condition is true.
Select the data range you want to apply conditional
formatting to.
– Press Alt-O, D SHORTCUT Press Alt-O, D
24
Importing and Organizing Data
Importing and Organizing Data
As a result you will be able to follow a methodical approach to importing and then organizing data
for analysis; thus enabling you to be successful where the data given to you by the client is in a
format that is unusable, and Excel is needed for analysis
26
Importing and Organizing Data
When importing data into Excel copy and paste usually does not work
• Copying and pasting text documents into Excel has limitations
• When it is copied from the text file into Excel, it is usually placed in separate
rows, but not in separate columns
• Open the orders.txt file, select all the data and select Edit Copy
• Paste the data into an Excel spreadsheet; notice how the content is pasted into
the workbook; cell A1 has all the contents of the first row of the text file and it is
not divided up into separate columns
• We need to use the Wizard in order to import this text file
27
Importing and Organizing Data
28
Importing and Organizing Data
29
Importing and Organizing Data
30
Importing and Organizing Data
• The last step in the wizard allows you to format the data you are importing to Excel
• For instance, if you know that you are importing a date field then you can select that
column and format it as a date by clicking the date radio button
• In this case we will leave all columns as General format so click Finish to finish
importing the data
31
Importing and Organizing Data
32
Importing and Organizing Data
Organizing data
• Sorting the data allows the user to arrange the data either ascending or
descending by one or multiple fields
• Before sorting, insert a numbered field in the first column called reset
Hint
allowing the user to resort the data to the original table setup when complete
33
Importing and Organizing Data
• Highlight the entire data set and select Sort from the Data ribbon
SHORTCUT Press Alt, D, S
• To return to the original set of data, repeat these steps, and then sort Ascending
by the Reset field
34
Importing and Organizing Data
35
Importing and Organizing Data
36
Importing and Organizing Data
• Concatenate allows you to combine the contents within multiple cells into one cell
with a text value
• In this situation, we want one field that lists the Contact Last Name, Contact First
Name
• We can use the Concatenate function in order to combine these and put a comma
in-between
• Concatenate(text1,[text2],…) returns the strings from the text combined into one cell
• In a new column titled Clean Name, create an equation to concatenate the last name
and first name with a comma in the middle
37
Pivot Tables
Pivot Tables
39
Pivot Tables
Path 1 Path 2
• From the Insert ribbon, select Pivot • Step 1 - Click on a cell on the page
and use the SHORTCUT Press Alt, D, P
Table
40
Pivot Tables
Path 1 Path 2
• Pivot table is created in a • Step 2 - Selecting a cell inside the data table
new worksheet before starting the Wizard, Excel will
automatically select the entire data range and it
will appear in the box
41
Pivot Tables
42
Pivot Tables
43
Pivot Tables
• Data fields represent the actual data that will be summarized by each row and column field
• We want to see the total cost for each manufacturing center, so add the “Price Paid to Suppliers”
field to the data area
44
Pivot Tables
• Excel automatically uses a function to summarize fields placed in the data area. In this case, it has
chosen the sum function to add up the prices paid by each manufacturing center
• Double Click on Sum of Price…. The PivotTable Field menu should be displayed. If you wished to
change the function to count, average, or many other functions, you can do so here
• Additionally, you can format the numbers displayed in the report here as well. By default, the numbers
will be in the regular number format, but for our purposes we would like it to be in the currency format.
• Click the Number button Under category select Currency Click OK twice to exit the menu
45
Pivot Tables
There are many helpful features that can help better present data within the PivotTable.
• You can access the Field Settings menu anytime by selecting a cell inside the
PivotTable, right-clicking, and selecting it from the menu
• The field settings menu will pertain only to the field area that you initially selected, i.e.,
if you select a cell within the data area under the Price Paid to Supplier field, the
settings you change will only correspond to that field
• To only view the total cost of manufacturing centers purchasing chlorine, click the
page pull-down tab (where we placed Raw Materials) and select Chlorine
• You can turn on/off Grand Totals by selecting a cell inside the PivotTable, right-
clicking, and going to Pivot Table Options
• When changing source data, ensure you refresh the Pivot table
46
Pivot Tables
47
Best Practices
Best Practices
Best Practices
49
Best Practices
Best Practices
50
Best Practices
Best Practices
Formatting
51
Appendices
52
More Functions for Importing, Cleaning,
and Organizing Data
Importing, Cleaning, and Organizing Data
54
Importing, Cleaning, and Organizing Data
55
Importing, Cleaning, and Organizing Data
Looking back at orders.txt, what are some issues you see with the imported data?
56
Importing, Cleaning, and Organizing Data
57
Importing, Cleaning, and Organizing Data
58
Importing, Cleaning, and Organizing Data
59
Importing, Cleaning, and Organizing Data
60
Importing, Cleaning, and Organizing Data
61
Importing, Cleaning, and Organizing Data
62
Importing, Cleaning, and Organizing Data
63
Importing, Cleaning, and Organizing Data
64
Importing, Cleaning, and Organizing Data
65
Other Helpful Tools
Other Helpful Tools
• Why is it useful?
• Grouping allows the user to continuously hide and unhide both rows and columns of
data
• In addition, it allows another viewer of the data to see that there are hidden rows and
columns where the hide rows and columns function does not
• When do you group data?
• When constantly hiding/unhiding data
• Group data together that is no longer relevant to the rest of the work on the page but
is important enough not to delete
• Group similar data together to make for easy navigation throughout large
worksheets
67
Other Helpful Tools
Use the Purchase Info sheet from the Combined Excel_July2008.xls file
• On the Purchase Info sheet, highlight columns D, E, and F
• Click Alt-D, G, G SHORTCUT Press Alt-D, G, G
• When grouped, you will see a minus sign and a line above the three columns
• Clicking the minus sign hides those the columns and makes the minus sign a plus
sign
• To ungroup, highlight the columns again and click Alt-D-G-U SHORTCUT Press Alt-D, G, U
68
Other Helpful Tools
Freezing panes
• Freezing panes allows a portion of the spreadsheet to stay stationary while the
rest of the spreadsheet scrolls up or down and left or right
• When is it useful?
• Scrolling down large tables and still wanting to see the labels in the top row
• Scrolling right in large tables and still wanting to see labels in the first column
• For example, in our file we always need to see the key and order columns
when scrolling right and the labels in the top row
69
Other Helpful Tools
Freezing panes
70
Other Helpful Tools
71
Other Helpful Tools
72
Other Helpful Tools
Data validation
A great tool to use if you want to limit what a user is allowed to input into cells or make data entry more
efficient. Example: We know that the only values we will be entering for the “Data Received” and
“Contract Received” is “Yes” or “No.” We can create a dropdown list that constrains the user to only
entering those two values.
• Highlight the range D13 to E56;
this is the area that we will
apply the Data Validation to
• From the Data ribbon, select
Data Validation SHORTCUT Press Alt-D, L
• Under Allow, click the dropdown
box and choose List because
the user will select from a
list of values
• In the source box type Yes, No
73
Other Helpful Tools
Data validation
74
Other Helpful Tools
Data validation
75
Other Helpful Tools
76
Other Helpful Tools
77
Reference Guide
Keyboard Shortcuts
80
Keyboard Shortcuts
81
Keyboard Shortcuts
Action Keystroke
Next application Alt + Tab
Active menu F10
83
Keyboard Shortcuts
85
Keyboard Shortcuts
Action Keystroke
Page setup Alt + P S P
Print Ctrl + P
86
Keyboard Shortcuts
Action Keystroke
Calculate all F9
Calculate worksheet Shift + F9
87
Functions
88
Functions
89
Functions
90
Functions
91
Functions
92
Functions
93
Functions
94
Functions
Conditional Home ribbon then select Styles Format cells based on user-defined
Formatting conditions
Auto Filter Data ribbon then select Sort & Filter Allows the user to filter out rows within
a data set based on certain cell
contents. The user will select the filter
criteria from a drop-down menu
95
Tools
96
Tools
97