0% found this document useful (1 vote)
78 views77 pages

Module 2 - Lecture Note - Introduction To Excel

Uploaded by

beckliss.nif
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
Download as pdf or txt
0% found this document useful (1 vote)
78 views77 pages

Module 2 - Lecture Note - Introduction To Excel

Uploaded by

beckliss.nif
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
Download as pdf or txt
Download as pdf or txt
You are on page 1/ 77

Introduction to Excel

INTRODUCTION TO EXCEL
What is Excel?
Popular spreadsheet software developed
by Microsoft
Work with data in a tabular format (rows,
columns)
Global presence
Relied on by businesses of all sizes
Offers free and paid versions

You can download Excel here.


Why Excel?
Excel can be used to store, process, analyze, and visualize data

Designed for technical and non-technical users

User-friendly interface
Supports collaboration via shared workbooks, co-authoring, comments and more

Templates to get you started with common tasks


Who uses Excel?
Industry/Department Use Cases:

Finance: accounting, budgeting, and forecasting

HR: performance monitoring, employee information


Retail: inventory tracking, sales tracking

Role Use Cases:

Analytics professional: everyday analytics tasks and research

Programmers: developing office applications, tools, add-ins, etc.

Management: tracking performance via dashboards


Limitations
Feature Max Limit
Limited by available memory and system
Open workbooks resources
Total number of rows and columns on a 1,048,576 rows by 16,384 columns
worksheet
Excel interface
Key definitions
Workbook: An Excel file containing one or more worksheets to help you organize all your
data.
Key definitions
Worksheet: primary area that you'll work in often referred to as a sheet or spreadsheet.
Consists of cells organized into columns and rows. Also known as a sheet.
Key definitions
Cell: box at the intersection of the grid where a row or column meet where information is
contained.
Key definitions
Cell reference: combination of a column letter and row number that identifies a cell in the
worksheet.
Key definitions
Active cell: refers to the cell that is being worked with, this is identified by a rectangular
green box.
Key definitions
Range: refers to two or more cells in a worksheet, these do not necessarily have to be
adjacent.
Key definitions
Formula: mathematical equations, cell references, or functions placed within a cell. All
formulas must started with an equal = sign.
Key definitions
Formula bar: bar located at the top of the worksheet next to the fx label. It's used to enter
or edit values/formulas.
Supported file formats
Excel files Text files

Excel Workbook ( .xlsx ) Text - Tab-delimited ( .txt )

Excel Macro-Enabled Workbook ( .xlsm ) CSV - Comma-delimited ( .csv )


Template ( .xltx )

Other file formats

OpenDocument Spreadsheet ( .ods )

Portable Document Format ( .pdf )


Navigating Excel
INTRODUCTION TO EXCEL

Loading workbooks
Working with data
Creating first formula
Loading Workbook

➢ Open the workbook called 1_1_loading_workbooks.xlsx from the


Workbooks folder.
➢ You can enlarge the Excel interface by clicking on the full-screen button in
the bottom right corner or by zooming out.
➢ On the worksheet Google Monthly Stock Price, select all values in column A.
➢ How many rows are contained in column A including the header?
Working with Data

➢ In this exercise, we'll be creating new worksheets within our workbook.


Create two worksheets, "Adding data" and "Pasting data".
➢ In the sheet Adding data, manually input the below data. This data will
span three columns and four rows. We recommend starting from the cell
reference A1.
Working with Data

➢ Navigate to the sheet you created earlier, Pasting data.


➢ Open the CSV file copying_data.xlsx from the Dataset folder. Do not close
your Excel workbook.
➢ Copy all data from columns A to K from the other Excel file and paste as
values into your workbook.
➢ The data looks messy; let's do some formatting to make the data easier to
read.
➢ Set the column width for all columns to 15.
➢ Ensure all column headers begin with a capital letter and the rest of
the column name is lowercase.
➢ What was the runtime for The Shawshank Redemption in minutes?
Create first formula

➢ Navigate to the Google Monthly Stock Price sheet on the worksheet we have been
working on
➢ Create a new column with the header "Open vs Close".
➢ In the second row, subtract the value in the Open column from the value in the Close
column.
➢ Copy the cell references from the second row of the Open vs Close column to row 121.
➢ Set the column width for all columns to 13
➢ Highlight all values in the column Open vs Close
➢ What is the open vs close price on when date was 3/1/2014?
➢ What was the average difference in open vs close price?
Working with tables
INTRODUCTION TO EXCEL
Tables in Excel
Column header row - First row in a table that
contains column headings

Body - Where all the rows of data and


formulas live that relate to our columns

Totals - Off by default, but can be enabled to


summarize all rows in a table
Benefits of using tables
Structured references Data integrity

Easy to read and understand Built-in data validation features

Reference columns by name in table Apply rules to columns for certain data
Dynamic and automatically updates as types

data is added or removed


Formatting your data
Tables Cells

Re-size table Customize fonts, alignment, data types

Apply slicers Apply conditional formatting


Create pivot tables Apply cell styles and cell themes

Apply style options and style designs


Filtering and sorting data
Filtering Sorting

Hides data you do not currently want to Integral part of data analysis
analyze Helps you quickly visualize and understand
Built-in comparison operations like greater your data better
than or top N Easier to find data when you know what
you're looking for

Sort by text, numbers, dates, and times


Sort by formatting: cell color, font color, and
icons
Adventure Works
Adventure Works

Column Name Details


OrderNo ID to identify each order
ItemCost The cost each item costs to make
ItemPrice The price each item sells for
OrderQuantity The number of items ordered
OrderDate The date the customer made the order
DeliveryDueDate The date the customer received the order
Product The item that was ordered
CustomerName The customers name
Managing data with
tables
INTRODUCTION TO EXCEL
Working with structured cell references

➢ Adventure Works is a global retail brand selling bikes, bike parts, and
accessories. You'll support their management team as an Analyst to help
them better understand their sales data.

➢ In this exercise, we are working with their Sales table which contains all
orders from 2017 to 2020. This will enable us start creating new calculated
columns and using structured references.

➢ Open 1_4_working_with_structured_references.xlsx from the Workbooks


folder.
Working with structured cell references

➢ Create a new column "OrderToDelivery" after the delivery due date column that
calculates the number of days between order and delivery for each row.
➢ Use a structured cell reference (the column name instead of the column reference).
Remember, to refer to a column name you'll need to use the @ sign.
➢ There are two ways that you can use a structured cell reference:
➢ Manually enter the column names using square brackets, for example:
[@DeliveryDueDate].
➢ Select the cell you would like to use as part of your formula by clicking on it.
➢ That doesn't look quite right! It's defaulted to a date… let's change it by changing the
data type to "Number".
➢ How many days on average does it take for Adventure Works to deliver once a customer
has placed an order?
Filtering data

➢ Filter the Sales table to display orders from 2020 only.


➢ Now it's time to sort your orders by two columns in the following priority:
➢ CustomerCountry (A-Z)
➢ OrderDate (Oldest to Newest)
➢ What is the order number for the first visible row in the table after the data
has been filtered and sorted?
Formatting tables

➢ Remove any previous filters applied from the last exercise, we want to see all
orders.
➢ Change the sort to only sort by OrderNo ascending.
➢ Format the following columns as Currency: ItemCost and ItemPrice.
➢ Format the following columns as Number with 0 decimal places:
SalesOrderLineKey, OrderQuantity, and OrderToDelivery.
➢ Format all other columns as as Text.
➢ Maybe it's time we change up the table style too! Navigate to Table Design and
select any table style you like.
➢ How many columns are formatted as text in our Sales table?
Aggregate and
Arithmetic
operations
INTRODUCTION TO EXCEL
Order of operations: problem
Math Problem:

20 × 2 − (1/2) × 10 × 22

Order of Operations

Parenthesis

Exponents

Division/Multiplication (left-to-right)

Addition/Subtraction (left-to-right)
Order of operations: solution
Math Problem:

20 × 2 − (1/2) × 10 × 22

Solution

1. Parenthesis: 20 × 2 − 0.5 × 10 × 22
2. Exponents: 20 × 2 − 0.5 × 10 × 4
3. Multiplication: 40 − 20

4. Subtraction: 20
Order of operations in Excel
Order of operations: Parentheses, Exponents, Division, Multiplication, Addition & Subtraction

Full Excel order of operations


Functions in Excel
Overview of aggregate functions
Aggregate functions: Summarize a group of values into a single result

Commonly used aggregate functions include:


SUM

AVERAGE

COUNT

MIN

MAX
Aggregate functions
University of DataCamp
Aggregate functions: Average
University of DataCamp

Average: central or typical value in a set of


numbers

Sum of all values divided by number of


records
Formula:
AVERAGE(B2:B11)

AVERAGE(B:B)

AVERAGE(Students[Test Score])

Output: 74.2
Aggregate functions: continued
Min: Minimum value in the column Max: Maximum value in the column

MIN() MAX()

Count: Number of records Sum: Total of all values in a column

COUNT() SUM()
Understanding
house prices
INTRODUCTION TO EXCEL
Summarizing sales

➢ Open 2_4_summarizing_sales.xlsx from the Workbooks folder.


➢ Write the following list of descriptions in the following cells:
➢ S2: "Lowest Item Price"
➢ S3: "Highest Item Price"
➢ S4: "Average Item Price"
➢ S5: "Total Sales"
➢ S6: "Total Profit"
➢ S7: "Profit Margin Ratio"
Summarizing sales

➢ In cell T2, calculate the lowest item price across all sales.
➢ In cell T3, calculate the highest item price across all sales.
➢ In cell T4, calculate the average item price across all sales.
➢ Format all three cells you've created to have the dollar currency to 2 decimal
places.
➢ What is the average item price for all sales at Adventure Works?
Calculating total sales

➢ Create a new column between E and F called "OrderLineSales".


➢ Order line sales can be calculated as the multiplication of order quantity and
item price.
➢ In cell U5, calculate the total sales for all rows based on our newly created
column OrderLineSales
➢ What is the total amount of sales the company has generated?
Profit margin ratio

➢ Create a new column between E and F called "OrderLineCost".


➢ Order line cost can be calculated as the multiplication of order quantity and item
cost.
➢ Create a new column between G and H called "OrderLineProfit".
➢ Order line profit can be calculated as OrderLineSales subtract OrderLineCost.
➢ In cell W6, calculate the total profit for all rows based on our newly created column
OrderLineProfit.
➢ In cell W7, calculate the profit margin ratio which divides total profit by total sales.
➢ Format this value as a percentage to one decimal place.
➢ What is the profit margin ratio for all sales?
Other functions in
Excel
INTRODUCTION TO EXCEL
Function categories
Inside Scope Outside Scope

Text Financial

Date & Time Logical


Maths & Trig Lookup References

Statistical Engineering

Cube

Information

Web

Compatibility
Text
LEFT() RIGHT()

Syntax: LEFT(text, [num_chars]) Syntax: RIGHT(text, [num_chars])


Description: returns the first character(s) in Description: returns the last character(s) in
a string based on the specified number of a string based on the specified number of
characters characters

Example: LEFT("DataCamp", 4) > Data Example: RIGHT("DataCamp", 4) > Camp


Text
UPPER() LOWER()

Syntax: UPPER(text) Syntax: LOWER(text)


Description: converts string to uppercase Description: converts string to lowercase
Example: UPPER("DataCamp") > Example: LOWER("DataCamp") > datacamp
DATACAMP
Date & Time
DATE()

Syntax: DATE(year,month,day)
Description: returns a sequential serial number that represents a particular date

Example: DATE(2020,10,31) = 2020/10/31


Date & Time
DAY()
Syntax: DAY(<serial_number>) .
Example: DAY(<serial_number>) .
Description: returns the day of a corresponding date as integer
YEAR()
Syntax: YEAR(serial_number)
Description: returns the year to a corresponding date as an integer
Maths & Trig
ROUND()
Syntax: ROUND(number, num_digits)
Description: returns a number rounded to a specified number of digits
Example: =ROUND(-1.475, 2) = -1.48
ABS()
Syntax: ABS(number)
Description: returns the absolute value of a number without it's sign
Example: ABS(-2) = 2
SUM()
Statistical
AVERAGE()

COUNT()

MIN()

MAX()
Applying formatting
functions
INTRODUCTION TO EXCEL
Product profiles

➢ Open 3_1_product_profiles.xlsx from the Workbooks folder.


➢ Create a new column between O and P called "Country".
➢ Write a formula that converts the customer country into uppercase
➢ To insert a new column, highlight column P and on the Home tab, select
Insert and then Insert Sheet Columns. This will create a new column to
the left.
➢ Your formula might look like this =UPPER(____)
➢ Wait… why is it only showing the formula? Well that's because Excel
thinks your formula is text.
➢ Convert the column to the data type General.
Product profiles

➢ Create a new column between A and B called "OrderID".


➢ Write a formula that takes the last 5 characters from OrderNo.
➢ Make sure that the column data type is General.
➢ To insert a new column, highlight column B and right-click. You'll then
see several options, you'll need to select Insert which creates a new
column to the left.
➢ Your formula might look like this =RIGHT(____, _).
➢ Under Home > Text there is a dropdown where you can change the
format. Select General.
➢ For OrderID: 43697, what is the total Order Line Profit? Answer to 2 decimal
places
Profit performance

➢ Create a new column "OrderYear" next to OrderDate that returns the year of the
order.
➢ Make sure that the column data type is Number and formatted to 0 decimal places.
➢ To insert a new column, highlight column K and on the Home tab, select Insert
and then Insert Sheet Columns. This will create a new column to the left.
➢ Your formula might look like this =YEAR([@OrderDate])
➢ Under Home > Date there is a dropdown where you can change the format.
Select Number.
➢ Create a new column "OrderMonth" next to OrderYear that returns the month of an
order.
➢ What is the average order line profit for 2020 orders?
Formatting with functions

➢ Unfilter your data from the previous exercise, so we can see all orders.
➢ Next to the summary statistics we created earlier, let's apply some rounding
to our lowest and highest item prices.
➢ In cells AB2 and AB3 apply a rounding up formula to 0 digits.
➢ Your formula might look like this =ROUNDUP(____, 0)
➢ In cell AB4, apply a standard rounding formula to 1 digit.
➢ What is the profit margin ratio when rounded to one digit?
Visualizing data in
Excel
INTRODUCTION TO EXCEL
Data visualization cheat sheet

1 https://www.datacamp.com/cheat-sheet/data-viz-cheat-sheet
What is data visualization?
Graphical representation of data using
charts, graphs, and other visual tools

Presentation of (complex) data:


Identify trends

Discover outliers

Enhances understanding and retention of


information

Critical part of the decision-making process


in data-driven organizations
Excel for data visualization
Offers a wide variety of ways to visualize your
data:

Simple 2D charts to complex 3D models

Customization options including:


Legends

Styles

Labels

Color schemes
Visualization options
Visualization options
How to visualize
data
INTRODUCTION TO EXCEL
Visualizing categories

➢ The operations team wants to understand which products perform best, so


let's visualize average sales across product categories. Excel has a variety of
options to represent categorical data effectively, so we'll use column or bar
charts to convey this information. These charts are powerful tools, enabling
concise and visually impactful data presentations.
➢ Close any files that you've currently got open.
➢ Open the workbook called 3_4_visualizing_categories.xlsx from the
Workbooks folder.
➢ Navigate to the By Product Subcategory sheet.
Visualizing categories

➢ From the Insert tab, create a 2D Column or 2D Bar chart to visualize Average
Sales by Product Subcategory.
➢ Select the range of data to include in the chart, in this case we can
simply click the table.
➢ With the data selected, go to the Insert tab and click on the Column icon
dropdown.
➢ Select the 2D Column or 2D Bar chart. For a basic column chart, you can
select the first option, which is labelled Clustered Column.
➢ Change the title of the chart to "Average Sales".
➢ Which category has the tallest column/bar and therefore has the highest
average sales?
Capturing parts of a whole

➢ The management team wants to explore how their orders vary from country to country
and state to state. We'll utilize a sunburst chart to visualize sub-categories within a larger
category. This powerful chart type allows us to visually represent the interconnectedness
and proportions of our data clearly and concisely. Sunburst charts are a type of treemap.
Capturing parts of a whole

➢ Navigate to the By Location sheet.


➢ Create a Sunburst chart to visualize Orders by Country and State.
➢ Select the range of data to include in the chart, in this case we can simply click
the table.
➢ With the data selected, go to the Insert tab and click on the Treemap icon
dropdown.
➢ Select the Sunburst chart.
➢ Change the title of the chart to "Orders by Country and State".
➢ Re-size the chart to make it easier to read.
➢ Which state in Australia has had the highest number of orders?
Capturing a trend

➢ Visualizing data over time can help find trends in sales performance. To achieve
this, we will utilize line charts. However, a crucial step will be editing the data
source, which we'll explore during the exercise. Line charts offer a powerful
means to represent trends and fluctuations, providing valuable insights into
sales patterns.
➢ Navigate to the By Date sheet.
➢ Create a line chart to visualize Total Sales by OrderYear and OrderMonth. It may
not look right initially, but don't worry - we'll fix that in the next step.
➢ Let's start by opening the Select Data Source pop-up.
➢ To open the Data Source pop-up, navigate to Chart Design tab and click the
Select Data option.
Capturing a trend

➢ Let's update the data source to:


➢ Total Sales as the Legend entries (series).
➢ Order Year and Order Month as the Horizontal (category) axis label. (Do not select the
column headers!)
➢ To update Legend entries (series): Remove the unnecessary columns by selecting them from
Legend entries (series) and selecting the "Remove" button.
➢ To update the Horizontal (category) axis label:
➢ Click the edit button and use the arrow pop-up to open an area to update your labels.
➢ Drag the range of data - all rows and columns for Order Year and Order Month.
➢ Next, click OK.
➢ Change the title of the chart to "Total sales over time".
➢ Re-size the chart to make it easier to read.
➢ Which month and year had the highest number of total sales? I.e. 1 2020
Congratulations!
INTRODUCTION TO EXCEL
Chapter 1
Chapter 2
Chapter 3
Become an Excel
master!
INTRODUCTION TO EXCEL

You might also like