Vous êtes sur la page 1sur 365

Changesin

Changes in Excel
Excel2013
2013

Just as
Just as you
you were
were getting
getting comfortable
comfortable withwith Excel
Excel 2010
2010 (or
(or maybe
maybe 2007),
2007), the
the
inevitable happened -- Microsoft released a new version, Excel
inevitable happened -- Microsoft released a new version, Excel 2013 -- and you2013 -- and you
have to
have tostart
start relearning
relearningagain.
again. Or
Or do
do you?
you? How
How much
much ofof what
what you
youknow
know about
about
Excel carries
Excel carries over,
over, with
with virtually
virtually no
no changes,
changes, toto Excel
Excel 2013?
2013? Fortunately,
Fortunately, the
thevast
vast
majority of
majority of what
what you
you do
do every
everyday
day doesn't
doesn't change
changeat atall.
all.Of
Of course,
course, there
thereareare
somenew
some new features
features and
and new new (hopefully
(hopefully simpler)
simpler) ways
ways ofof performing
performingfamiliar
familiar
tasks, and
tasks, andthe
themost
most important
important of of these
these are
are described
described in
in new
new ExcelNow!
ExcelNow! topics,
topics,
starting with
starting with the
thetopic
topic you
you are
are currently
currentlyreading.
reading.

Perhaps the
Perhaps thefirst
first thing
thing you
you will
will notice
noticeisisthe
the new
new look.
look. For
For whatever
whatever reason,
reason,
Microsoft decided
Microsoft decidedto to give
giveOffice
Office 2013
2013 aastarker,
starker, more
more stylized
stylized look.
look. You
You can
can see
see
this as
this as soon
soon as
as you
youopenopen Excel
Excel 2013
2013 (or
(or any
anyofof the
the other
other Office
Office2013
2013
applications). For
applications). For example,
example, thethe tabs
tabs at
at the
thetop
top are
are now
now allall in
inuppercase,
uppercase, andand the
the
ribbons are more abstract. (See the comparison of the Insert
ribbons are more abstract. (See the comparison of the Insert ribbons to the ribbons to the
right, for
right, for example.)
example.) Also,
Also, try
try selecting
selecting individual
individual cells
cells or
or ranges
ranges to tothe
the right,
right, and
and
you will
you will see
see how
how the the selection
selection seems
seems toto "follow"
"follow" the
the cursor
cursor ---- aanice
nicetouch.
touch.

Also, you
Also, youwillwill notice
noticethat
that when
whenyou
youlaunch
launchExcel,
Excel, you
you get
get the
the options
options shown
shown toto
theright
the right ---- you
you don't
don't automatically
automatically seeseeaa blank
blank worksheet.
worksheet. However,
However, you
youcan
can
easilyclick
easily click the
the Blank
BlankWorksheet
Worksheetoption,
option, or
or you
you can
can choose
choose from
from many
many other
other
options. Also,
options. Also, ifif you
you click
click the
theFile
File tab
tab and
and then
then Info,
Info, you
you see
see the
the options
optionsbelow
below
(scroll down to see them), which differ somewhat from those
(scroll down to see them), which differ somewhat from those in Excel 2010. in Excel 2010.
Insert ribbon in Excel 2010

Insert ribbon in Excel 2013


Single Document
Single Document Interface
Interface

Excel 2013
Excel 2013 isis now
now like
likeprevious
previous versions
versionsof of Word
Wordhave
havebeen
beenfor
for years.
years. InIn previous
previous
versions of Excel, if you opened several spreadsheet files, they all shared aa single
versions of Excel, if you opened several spreadsheet files, they all shared single
window. You
window. You could
couldseesee several
several at
atonce
once only
only by
by using
using Excel's
Excel's View
View Side
Side by
bySide
Side
feature(or
feature (or byby opening
opening aasecond
second instance
instance of ofExcel).
Excel).In
In contrast,
contrast, different
different Word
Wordfiles
files
all got
all gottheir
their own
own windows.
windows.Excel
Excel 2013
2013 isis now
now like
like Word.
Word.Each
Each spreadsheet
spreadsheetfile file
opens into
opens into its
its own
ownwindow.
window. Technically,
Technically, previous
previous versions
versions ofof Excel
Excel used
usedaa multiple
multiple
document interface,
document interface, oror MDI.
MDI. In
In contrast,
contrast, Excel
Excel 2013
2013 uses
uses aa single
single document
document
interface, or
interface, or SDI.
SDI.

This change
This changewill will probably
probablytake takeyouyouaa while
while to
to get
get used
used to, to, and
andthere
there isis no
no doubt
doubt
that some
that someusers
users will
will like
like itit and
and others
others won't.
won't. But
But itit isis definitely
definitelynownow easier
easier toto see
see
two or
two or more
morespreadsheet
spreadsheet files files simultaneously.
simultaneously. For For example,
example, ifif you
you have
have two two side-
side-
by-side monitors,
by-side monitors, you you cancanopen openone one Excel
Excel file
fileand
andmove
move its its window
window to to the
theleft
left
monitor, and you can open a second Excel file and move
monitor, and you can open a second Excel file and move its window to the right its window to the right
monitor.(In
monitor. (In addition,
addition, you you can can still
still use
use the
the View
View Side
Side by bySide
Side feature
feature in in the
theView
View
ribbon to
ribbon tosee
see both
both windows
windows on onaa single
singlemonitor.
monitor. Also,
Also, Ctrl+Tab
Ctrl+Tab still
still lets
lets you
you switch
switch
from one
from one file
file to
to another.)
another.)

Try it!
Try it! Open
Open one
oneor
or more
more Excel
Excel files,
files, in
inaddition
addition toto this
this one,
one, and
andnotice
noticehow
how each
each
getsits
gets its own
own window.
window.Then
Then reposition
reposition or or resize
resizethem
themso sothat
thatyou
youcan
cansee
see them
them all
all
at once.
at once.
QuickAnalysis
Quick Analysis

IfIf you
youread
readpreviews
previews ofof Excel
Excel 2013
2013on on the
the Web,
Web, thisthis topic
topic isis probably
probablythethe most
most
prominently advertised feature you saw. Starting with a data
prominently advertised feature you saw. Starting with a data set such as the one set such as the one
to the
to the right,
right, the
thenew
new Quick
QuickAnalysis
Analysis tools
tools provide
provideyou youwith
with instant
instantconditional
conditional
formatting, pivot
formatting, pivot tables,
tables, charts,
charts, and
andother
other results
resultswithwith almost
almost no no work.
work. You
Youcan
can
decide how
decide how useful
useful this
this new
new feature
featurereally
really is.
is.ItIt undoubtedly
undoubtedlygives gives you
you very
very quick
quick
results, but
results, butthe
thequestion
question isis whether
whether itit gives
gives you
you thetheresults
results youyou want.
want.
To see
To see how
how this
this works,
works, select
select the
the entire
entire data
datarange
rangetoto the
theright,
right, including
includingthethe
labels in
labels in row
row 3.
3.You
Youwill
will see
see aa Quick
Quick Analysis
Analysis icon
icon atat the
the bottom
bottomrightright of
of the
the data
data
range. When
range. When youyou click
click this
this icon
icon(or
(or press
press Ctrl+q),
Ctrl+q), youyou bring
bringup up the
theoptions
options shown
shown
below the
below thedata
dataset
setto
to the
theright.
right. From
Fromthere,
there, you
you cancan explore
explore the thepossibilities.
possibilities.They
They
areall
are all straightforward.
straightforward.

As an
As an example,
example, ifif you
you choose
choose Tables
Tables and
andthen
then choose
choose the
the first
first of
of several
several automatic
automatic
pivot tables, you get the pivot table on the next sheet, which
pivot tables, you get the pivot table on the next sheet, which breaks down thebreaks down the
sum of
sum of Total
Total Cost
Cost by
by Region.
Region. This
Thismight
might oror might
might not
notbe
be the
the pivot
pivottable
table you
you really
really
want, but
want, butatat least
least itit gives
gives you
you aapivot
pivot table
tablethat
that you
you can
canthen
then modify
modify asas you
you like.
like.
Similar statements
Similar statements can can be
be made
made about
aboutthethe automatic
automatic charts
charts available
availablefrom
from the
the
Charts item.
Charts item.TheThequestion
questionisiswhether
whether this
thisisisany
anyeasier
easier than
than building
building the
the pivot
pivot
table or
table or the
thechart
chartyouyoureally
really want
wantfrom
from scratch.
scratch.Again,
Again, you
you can
can be
be the
the judge.
judge.

Twoof
Two of these
these Quick
Quick Analysis
Analysisoptions
options are
are duplicated
duplicated byby two
two new
new Excel
Excel 2013
2013 "let
"let us
us
guess what you want" items in the Insert ribbon, shown below. These
guess what you want" items in the Insert ribbon, shown below. These are the are the
Recommended PivotTables
Recommended PivotTablesandand Recommended
RecommendedCharts Chartsitems.
items.They
They provide
provide exactly
exactly
thesame
the same options
options for
for pivot
pivottables
tables and
andcharts
chartsasas from
from the
the Quick
Quick Analysis
Analysis tools.
tools.
Date Day Time Region Card Type Gender Buy Categos Ordered Total Cost High Item
6-Mar Tue Morning West ElecMart Female High 4 $136.97 $79.97
6-Mar Tue Morning West Other Female Medium 1 $25.55 $25.55
6-Mar Tue Afternoon West ElecMart Female Medium 5 $113.95 $90.47
6-Mar Tue Afternoon NorthEast Other Female Low 1 $6.82 $6.82
6-Mar Tue Afternoon West ElecMart Male Medium 4 $147.32 $83.21
6-Mar Tue Afternoon NorthEast Other Female Medium 5 $142.15 $50.90
7-Mar Wed Evening West Other Male Low 1 $18.65 $18.65
7-Mar Wed Evening South Other Male High 4 $178.34 $161.93
7-Mar Wed Evening West Other Male Low 2 $25.83 $15.91
8-Mar Thu Morning MidWest Other Female Low 1 $18.13 $18.13
8-Mar Thu Morning NorthEast ElecMart Female Medium 2 $54.52 $54.38
8-Mar Thu Afternoon South Other Male Medium 2 $61.93 $56.32
9-Mar Fri Morning NorthEast ElecMart Male High 3 $147.68 $96.64
9-Mar Fri Afternoon NorthEast Other Male Low 1 $27.24 $27.24
10-Mar Sat Morning West Other Female Low 3 $46.18 $44.27
10-Mar Sat Afternoon West Other Male Low 5 $107.44 $91.64
10-Mar Sat Afternoon South ElecMart Female Medium 6 $96.53 $93.68
10-Mar Sat Afternoon West ElecMart Female Medium 4 $77.44 $77.28
11-Mar Sun Morning South Other Male Low 1 $15.19 $15.19
11-Mar Sun Afternoon South Other Male Medium 1 $45.52 $45.52

Quick Analysis options

New items in Excel 2013 Insert ribbon


Flash Fill
Flash Fill

Has Excel
Has Excel 2013
2013become
become aamind mind reader
reader with
with its
its new
new Flash
Flash Fill
Fill tool?
tool? You
You might
might think
think
so after
so after you
you read
readthisthis topic.
topic. However,
However, it's
it's not
not really
really about
about mind
mind reading
reading but
but rather
rather
about the
about theability
ability to
torecognize
recognize patterns.
patterns.

Specifically, Flash
Specifically, Flash Fill
Fill allows
allowsyou you toto parse
parse names,
names, numbers,
numbers, or or dates
dateswithout
without any
any
formulas ifif the
formulas the items
items in in your
your list
listfollow
follow aa definite
definitepattern.
pattern.AA typical
typical example
examplewhere
where
itit applies
applies isis in
inthe
the list
listof
of names
names to tothe
the right.
right.Each
Each name
name follows
followsaa pattern:
pattern: last
last
name, comma
name, comma and andspace,
space, first
first name,
name, space,
space, middle
middle initial
initial and
and period.
period.Row
Row 55
illustrates the
illustrates the desired
desired results
results inin blue.
blue. There
Thereare
aretwo
two ways
ways to to proceed.
proceed. You
Youcan
cantry
try
bothmethods.
both methods.

1.Type
1. Type the
thefirst
firstname
namein
inthe
thetop
top row:
row: Bob
Bobin
in cell
cell L8.
L8.Then,
Then, with
with cell
cell L8
L8selected,
selected,
select Flash Fill from the Fill dropdown on the Home ribbon. Pretty amazing,
select Flash Fill from the Fill dropdown on the Home ribbon. Pretty amazing, huh? huh?
Now you
Now you can
can repeat
repeatwith
with the
theother
other columns.
columns.

2.Type
2. Type the
thefirst
firstname
namein inthe
thetoptop row:
row: Bob
Bobin in cell
cell L8.
L8.Then
Thenstart
start typing
typingthe
thenext
next
first name in the second row: Stephen in cell L9. Pretty soon, Excel
first name in the second row: Stephen in cell L9. Pretty soon, Excel will guess andwill guess and
show you
show you the
thepattern
pattern for
for all
all rows
rows in
in light
lightfont,
font, at
at which
which time
time you
youcancanpress
press Enter
Enter
toaccept
to accept the
theresults.
results.Again,
Again, youyou can
can now
now repeat
repeat with
withthe
the other
other columns.
columns.

Notehow
Note how Flash
Flash Fill
Fill can
canrecognize
recognize many
manypatterns,
patterns, such
such asas the
theinitials
initials in in column
column QQ
and the
and thelower
lower case
case name
name in incolumn
columnR. R.However,
However, ifif names
names don't
don't fit
fit the
the pattern,
pattern,
Flash Fill
Flash Fill will
willlikely
likely fail.
fail.For
For example,
example, replace
replacethe
thebottom
bottomtwo two names
names with withLincoln,
Lincoln,
Abeand
Abe and Fitzgerald,
Fitzgerald, F.F. Scott
Scott and
and see
see what
what Flash
Flash Fill
Fill does.
does.Unfortunately,
Unfortunately, this this shows
shows
that Flash Fill can't completely take the place of text functions for all
that Flash Fill can't completely take the place of text functions for all parsing tasks. parsing tasks.
Flash Fill
Flash Fill also
also works
works on oncertain
certain patterns
patterns of
of numbers
numbersand and dates,
dates, asas you
you cancan check
check
on the
on the examples
examples to tothethe right.
right.However,
However, except
except for
for the
the year
year column
column on onthe
the dates,
dates,
only method
only method 11seems seems to to work.
work. We're
We're not
notsure
sure why
why method
method 22works
works in in some
some
situations but
situations but not
notininothers.
others.
Results for a typical name
Roberts, Julie T. Julie T. Roberts Julie Roberts Julie T. Roberts JTR

Names to parse
Jones, Bob E.
Davis, Stephen T.
Thompson, Andy S.
Wilson, John T.
Kelley, Jennifer B.
Williams, Karen S.
Smith, Tom F.
Jennings, Peter R.
Benson, Ted A.
Samson, Jason T.

Results for a typical number Results for a typical date


123.78 123 78 2/21/2013 2013 2

Numbers to parse Dates to parse


12658.9 1/3/2012
540.99 3/26/2000
231.29 5/7/1999
32478.18 4/4/2008
53.67 6/17/1976
93.1 3/29/2000
4754.123 12/25/2014
julie roberts

21
Going Home
Going Home to
to Cell
Cell A1
A1

When you
When you are
are working
working on
onaa large
large worksheet,
worksheet, you
you often
often want
want to
to reorient
reorient
yourself by going back to cell A1, the "home" cell. This is easy. Just press
yourself by going back to cell A1, the "home" cell. This is easy. Just press
Ctrl+Home from
Ctrl+Home from anywhere
anywhere ininaa worksheet,
worksheet, and
andyou
youwill
will go
go to
to cell
cell A1.
A1.

Try it!
Try it! Scroll
Scroll way
waydown
down and
and way
wayacross
across to
to the
the right.
right.Then
Then press
pressCtrl+Home.
Ctrl+Home.
Moving Around
Moving Aroundwith
withEnd,
End, Arrow
Arrow Combinations
Combinations

ItItisis often
often useful
useful to
to zoom
zoom to
tothe
the bottom,
bottom, top,
top, left,
left, or
or right
right edge
edge ofof aa data
data range.
range. You
You can
can do
do
this easily with the End-arrow key combinations. (See the last text box
this easily with the End-arrow key combinations. (See the last text box below for other below for other
keyboardoptions.)
keyboard options.)

To go
To goto
to the
theend
endof
of aarange
range(top,
(top, bottom,
bottom, left,
left, or
or right):
right):

Press the
Press the End
End key,
key, then
thenthe
the appropriate
appropriate arrow
arrow key.
key. (Let
(Let go
go of
of the
the End
End key
key before
before pressing
pressing
thearrow
the arrow key.)
key.) For
For example,
example, press
press End
End and
and then
then right
right arrow
arrow toto go
go to
to the
the right
right edge
edge of
of aa
range.
range.
Tryit!
Try it! Starting
Starting at
at aa corner
corner (a
(a bordered
borderedcell)
cell) of
of the
the blue
bluerange
rangeto
to the
theright,
right, move
move around
aroundto
to
theother
the other corners.
corners.

Selecting Ranges
Selecting Ranges with
with End,
End, Arrow
Arrow Combinations
Combinations

IfIf you
youkeep
keep your
your finger
finger on
on the
theShift
Shiftkey
keywhile
while you
you do
do an
an End,
End, Arrow
Arrow combination,
combination, you
youwill
will
select the
select therange
rangeinin between.
between.

Tryit!
Try it! Starting
Starting at
at aa corner
corner (a
(a bordered
borderedcell)
cell) of
of the
the red
redrange
range to
to the
the right,
right, move
move around
aroundto
to the
the
other corners.
other corners.But
But this
thistime,
time, keep
keep your
your finger
finger on
on the
the Shift
Shiftkey.
key.

HowEnd,
How End, Arrow
ArrowCombinations
Combinations Really
Really Work
Work

Notethat
Note that the
the action
action of
of an
anEnd, End, Arrow
Arrowcombination
combination depends
depends on on where
whereyou youstart.
start. ItIt takes
takes you
you
to the
to the last
lastnonblank
nonblank cell
cell ifif you
you start
startin
inaa nonblank
nonblank cell.
cell. (If
(If there
there arent
arent any
anynonblank
nonblank cells cells in
in
that direction,
that direction, itittakes
takesyou
you to to the
thefar
far edge
edge of
of the
the sheet.)
sheet.) IfIf you
you start
start in
in aa blank
blank cell,
cell, itit takes
takes
you to
you to the
the first
first nonblank
nonblank cell.cell.

Tryit!
Try it! Move
Move around
aroundthe
the green
greenrange
rangeto
to the
the right,
right, where
where there
there are
are some
someblank
blank cells.
cells.

Other Keystrokes
Other Keystrokes for
for Moving
Moving Around
Around or
or Selecting
Selecting

There are
There are other
other keystroke
keystroke combinations
combinationsthatthathave
havethe
thesame
sameeffects.
effects.Instead
Instead of
of an
an End-arrow
End-arrow
combination, you
combination, youcan canpress
press the
the Ctrl
Ctrl key
key and
and an
anArrow
Arrow key
key at
at the
thesame
sametime
timetoto move
moveto
to the
the
edge of
edge of aarange.
range. IfIf you
you also
also hold
holddown
downthetheShift
Shift key,
key, you
youselect
select the
therange
rangefrom
from where
where you
you
start to
start to the
the edge.
edge.

Also, ifif you


Also, you want
want to
to select
select aadata
data range,
range, even
evenone
one with
withsome
some blanks
blanks as
asin
inthe
the green
greenrange
range
above, put
above, put your
your cursor
cursor ininany
anyof
of the
the cells
cellsand
and press
press Ctrl+a.
Ctrl+a. (Think
(Think of
of"a"
"a" for
for "all".)
"all".)
edge of
edge of aarange.
range. IfIf you
you also
also hold
holddown
downthe
theShift
Shift key,
key, you
youselect
select the
therange
rangefrom
from where
where you
you
start to
start to the
the edge.
edge.

Also, ifif you


Also, you want
want to
to select
select aadata
data range,
range, even
evenone
one with
withsome
some blanks
blanks as
asin
inthe
the green
greenrange
range
above, put
above, put your
your cursor
cursor ininany
anyof
of the
the cells
cellsand
and press
press Ctrl+a.
Ctrl+a. (Think
(Think of
of"a"
"a" for
for "all".)
"all".)
8 1 1 1
5 5 7 6
10 5 3 10
10 10 5 9
5 4 3 4
7 4 5 1
2 8 9 10

8 1 1 1
5 5 7 6
ouwill
ou will
10 5 3 10
10 10 5 9
und to the
nd to the 5 4 3 4
7 4 5 1
2 8 9 10

8 1 1
5 5 7
takes you
takes you
k cells
cells in
in 10 5 3 10
it takes
t takes 10 10 9
4 3 4
. 7 4 5 1
2 9 10

nd-arrow
nd-arrow
eeto
to the
the
re you
e you

range
range
re you
e you

range
range
Splitting the
Splitting the Screen
Screen Horizontally
Horizontally and/or
and/or Vertically
Vertically

ItItisisoften
oftenuseful
useful to
to split
split the
thescreen
screen so
sothat
that you
you can
cansee
see more
more information.
information.

To split
To splitthe
the screen
screenvertically,
vertically, horizontally,
horizontally, or
or both:
both:

Click on
Click on the
thenarrow
narrow screen
screen splitter
splitter bar
bar just
justto
to the
theright
right of
ofthe
the bottom
bottom scroll
scroll bar
bar
(for vertical splitting) or just above the right-hand scroll bar (for horizontal
(for vertical splitting) or just above the right-hand scroll bar (for horizontal
splitting) and
splitting) anddrag
dragthis
this to
to the
the left
left or
or down.
down.(See
(Seethethe screenshot
screenshot below.)
below.)

Splittinggives
Splitting givesyou
you two
two panes
panes (or
(or four
four ifif you
yousplit
splitin
in both
both directions).
directions). Once
Onceyou
you
have these panes, practice scrolling around in any of them, and see
have these panes, practice scrolling around in any of them, and see how the how the
othersreact.
others react.

Try it!
Try it! Split
Splitthe
the screen
screen both
both ways
ways so
so that
that you
you can
can see
see the
thetop
top left
leftcell
cell and
and the
the
bottom right cell in the data set to the right. Then remove the
bottom right cell in the data set to the right. Then remove the splits. splits.

Caution: You
Caution: Youcancan remove
removethe thesplits
splitsbybydragging
dragging thethehorizontal
horizontal splitter
splitter up
up or
or down.
down.
IfIf you
you move
move ititdown,
down, youyou won't
won't find
find the
the splitter
splitter icon
iconat
at the
the top
top of
of the
thescrollbar
scrollbar as
as
shown below; it will appear at the bottom of the scrollbar. Similarly,
shown below; it will appear at the bottom of the scrollbar. Similarly, you might you might
find the
find the vertical
vertical splitter
splitter icon
iconto
to the
the lef
lef of
of the
the bottom
bottom scrollbar,
scrollbar, not
nottoto the
theright
right as
as
shown below.
shown below.
61 91 84 8 3 62 11 33 83 70
95 8 14 68 33 23 13 12 3 100
33 93 80 5 60 30 13 34 23 57
49 47 37 41 56 38 46 50 100 40
10 65 46 42 52 90 37 31 56 29
14 69 15 73 11 75 77 36 66 32
21 80 46 93 35 95 35 95 27 25
8 74 24 77 9 92 46 28 100 22
94 33 56 88 51 73 22 39 93 77
84 17 60 87 32 46 100 61 83 71
62 79 43 80 11 9 24 52 22 58
16 29 76 6 90 32 40 62 94 34
93 54 2 11 82 33 18 31 42 58
6 39 52 66 33 2 23 49 87 46
28 91 57 78 29 82 24 88 45 3
66 28 57 51 87 44 99 18 32 34
56 100 36 48 46 60 71 33 30 26
3 34 87 45 45 76 85 86 28 100
33 13 50 83 53 20 83 13 7 27
34 55 3 9 67 99 25 33 93 18
80 45 89 83 23 31 12 14 27 75
53 96 54 41 100 1 28 21 29 68
77 57 38 52 44 94 46 72 50 83
64 86 26 30 35 69 52 28 48 27
39 28 43 41 27 86 76 44 12 47
75 97 99 71 66 63 42 63 15 91
58 14 66 95 35 18 41 32 29 35
56 58 57 81 48 63 27 54 97 81
5 99 11 59 7 8 84 56 76 54
80 67 47 99 77 50 42 90 92 86
6 22 30 3 40 19 67 32 57 49
52 100 67 91 27 59 11 72 12 79
83 32 19 90 44 22 100 11 18 68
8 51 93 30 28 55 97 60 46 59
55 21 30 49 5 26 1 16 86 85
51 88 93 61 96 88 59 68 44 95
39 97 37 14 25 17 44 69 92 16
50 80 41 96 76 49 43 27 73 88
42 73 4 25 21 30 74 44 68 36
48 60 26 34 87 79 62 96 39 45
54 12 31 66 87 68 48 34 46 29
15 63 54 42 15 32 73 11 91 96
28 41 18 72 18 36 54 96 3 50
28 15 100 28 4 9 94 43 56 98
99 3 52 27 39 60 4 18 63 56
24 32 55 62 100 30 82 17 79 11
19 28 46 73 83 78 96 39 32 42
21 31 14 78 87 14 49 85 75 84
30 76 53 91 46 94 2 64 34 41
93 98 84 86 97 9 98 94 44 61
32 54 80 51 59 62 6 8 29 4
35 32 25 34 37 83 51 54 45 52
82 86 46 28 54 56 26 57 3 67
23 94 71 95 56 37 97 84 7 68
59 62 88 21 2 57 19 66 65 32
17 19 95 63 4 99 93 50 100 2
4 62 36 55 37 49 11 62 7 70
67 58 54 91 39 76 25 22 55 23
17 41 21 18 24 6 65 10 83 45
71 8 45 90 1 34 11 60 21 93
48 41 36 7 69 54 5 9 46 46
29 97 30 76 59 85 39 96 30 40
58 15 37 56 25 71 3 78 83 65
64 66 57 26 39 63 17 46 76 99
14 48 78 6 72 26 1 84 26 48
67 56 76 7 97 89 44 99 19 73
90 97 41 63 79 20 90 95 87 92
83 17 24 75 31 11 98 72 91 5
21 32 27 46 59 22 82 12 65 48
14 27 3 62 48 39 43 8 81 19
38 87 57 5 39 100 56 61 5 62
64 15 57 23 94 63 96 6 54 27
10 24 39 52 80 100 28 88 21 15
53 10 66 31 7 99 48 21 85 20
79 70 94 39 66 37 7 78 57 92
90 19 84 3 4 48 34 91 41 11
60 59 36 83 90 42 45 17 64 83
67 9 71 3 84 2 95 44 67 18
22 53 52 45 50 20 39 23 68 48
80 17 94 59 82 93 50 47 67 46
86 16 44 67 60 14 38 99 57 37
41 46 51 42 50 52 38 16 49 60
8 66 13 63 76 23 58 1 70 47
58 52 88 11 35 21 57 6 14 82
9 10 80 57 97 49 89 1 5 83
21 23 18 11 83 7 50 96 3 33
64 79 96 60 21 49 80 80 80 52
59 93 64 38 26 71 1 66 39 49
18 54 3 25 10 80 46 49 26 52
17 49 70 22 71 98 81 44 23 94
22 24 96 90 79 26 13 63 60 59
72 62 35 54 98 13 94 56 28 85
56 81 96 90 42 44 88 33 37 61
10 95 47 39 40 74 48 72 44 83
72 77 68 43 75 89 23 27 53 55
72 46 33 91 76 68 54 82 74 73
94 62 70 62 1 71 46 49 90 97
44 16 63 96 93 42 98 36 32 31
4 78 4 57 89 63 14 63 11 40
44 53 42 63 53 73 15 21 38 47
80 8 23 12 57 71 55 48 77 6
41 77 13 57 84 1 92 13 19 73
21 28 20 14 34 77 12 47 30 32
35 79 17 53 48 31 52 29 16 42
44 19 27 44 81 54 47 8 24 67
38 82 78 93 9 49 1 20 76 63
45 91 77 37 45 46 5 71 47 15
47 24 39 50 25 65 52 71 14 24
64 36 57 8 7 85 97 6 16 11
79 62 44 21 75 43 58 44 84 64
25 11 56 79 80 68 68 25 21 63
47 1 96 34 33 30 92 70 17 3
2 65 45 17 6 16 19 61 9 23
73 21 96 87 87 33 95 99 19 92
97 29 26 8 25 35 27 30 69 28
62 31 48 1 100 11 71 77 87 38
22 42 23 87 55 73 89 22 73 27
48 12 99 78 21 25 58 88 4 39
63 62 60 7 95 7 9 20 37 63
59 83 41 52 33 77 59 28 78 49
23 53 55 94 79 73 53 45 93 69
73 85 62 26 65 82 48 55 5 82
87 76 44 15 5 76 8 73 54 18
25 36 61 5 95 95 55 44 81 51
87 49 6 24 96 32 90 43 43 36
1 65 3 98 88 93 52 26 76 97
25 7 5 62 60 41 36 43 94 66
3 15 36 21 81 37 48 67 87 79
21 88 92 53 26 82 74 30 71 37
46 8 27 24 80 66 74 33 76 70
41 32 70 57 7 68 37 55 84 29
74 5 50 73 14 35 70 87 65 56
8 52 77 79 18 82 17 29 56 56
64 28 1 99 41 63 89 69 97 26
60 75 59 23 50 98 8 91 84 25
24 32 42 22 45 40 78 92 9 76
66 100 97 47 89 46 89 73 33 29
5 21 61 56 43 59 39 19 41 82
51 11 13 49 60 16 15 94 67 91
80 38 15 55 84 4 68 40 85 2
69 59 95 21 59 78 9 59 36 68
44 43 36 99 84 57 72 11 93 84
36 96 63 2 69 5 56 70 66 65
90 35 33 45 100 95 30 23 92 15
29 11 97 85 100 17 81 87 5 71
87 99 83 90 96 54 33 56 59 32
80 41 1 99 56 87 85 74 85 29
67 86 89 90 17 97 64 6 43 23
78 98 73 2 43 55 81 46 6 58
59 7 61 27 45 25 32 47 66 95
50 65 6 73 62 5 96 69 65 21
91 58 44 11 100 82 50 28 26 93
36 92 28 37 38 4 30 99 17 88
93 31 27 55 85 54 65 94 90 56
31 42 27 37 83 42 5 43 24 68
32 76 74 40 8 61 46 73 31 92
36 13 30 44 71 60 83 68 76 20
10 72 34 68 46 1 35 84 32 34
51 41 64 66 64 25 66 21 38 45
54 51 44 70 39 66 38 21 74 64
18 22 68 19 62 49 31 98 76 84
20 36 76 29 14 36 22 14 68 87
84 81 83 45 67 76 65 53 76 100
2 32 35 35 77 100 51 81 67 46
80 80 49 44 55 44 25 53 58 86
6 73 48 54 20 12 73 27 82 47
55 88 39 92 91 88 70 97 86 53
6 14 68 28 42 87 68 86 16 68
6 85 2 88 9 46 3 68 30 79
48 82 90 87 29 56 68 54 49 100
49 16 70 33 38 89 89 38 22 56
89 65 76 38 66 65 90 52 67 74
82 96 81 70 57 16 56 37 50 6
29 39 13 40 71 72 68 55 21 65
11 49 96 18 36 30 71 10 51 32
43 21 73 40 37 28 24 4 14 56
17 77 29 50 77 10 53 30 55 77
100 87 58 88 19 44 54 82 62 18
65 56 63 89 78 60 49 39 34 92
26 50 7 90 32 25 80 80 9 77
85 4 11 95 8 72 16 30 36 6
27 34 52 95 58 72 88 48 92 13
74 50 36 79 4 91 62 30 79 44
90 4 53 74 9 37 100 77 22 19
81 67 18 3 36 41 24 51 89 8
87 10 62 20 81 35 2 71 26 27
85 30 97 86 13 26 91 11 80 60
63 71 10 68 99 9 92 4 75 99
8 18 40 81 20 19 21 59 12 4
14 23 86 50 65 69 52 75 28 71
70 68 65 22 38 67 79 97 13 88
35 20 39 36 60 83 62 69 11 42
24 42 69 77 10 87 33 4 55 91
66 34 71 48 48 54 45 82 35 14
75 35 7 53 28 9 82 61 82 66
47 61 39 77 63 54 89 92 56 91
75 83 38 56 55 5 96 90 75 65
62 32 49 76 59 48 40 29 33 60
90 2 31 1 86 96 41 11 89 62
9 4 60 71 6 49 33 19 31 56
58 47 83 28 10 39 15 71 84 84
87 29 30 76 72 11 91 2 71 60
5 37 65 32 8 44 42 90 84 68
71 55 13 82 26 58 53 81 39 6
40 27 2 33 73 3 87 10 58 82
77 90 32 82 40 62 49 32 60 4
62 31 22 48 69 66 28 54 3 58
75 7 75 57 36 24 65 72 21 69
68 54 34 43 18 89 25 1 94 64
68 17 81 73 51 24 99 49 99 95
60 53 39 63 39 49 52 66 37 69
38 44 18 1 14 6 88 7 8 87
13 2 66 24 33 64 9 73 50 100
65 78 33 93 61 75 81 47 24 10
11 74 100 95 33 87 58 14 10 41
100 79 1 30 38 38 2 52 10 76
93 77 58 4 76 71 79 10 7 40
99 39 52 60 13 65 16 90 12 57
47 15 65 34 2 49 3 68 46 42
62 100 64 94 41 79 3 11 9 23
36 37 100 34 96 54 46 34 58 61
50 30 8 81 33 75 76 68 2 39
71 63 57 70 12 93 83 29 96 51
33 54 72 49 3 68 38 97 81 6
68 32 91 5 34 66 31 25 69 89
80 89 86 36 50 78 81 78 8 4
82 22 53 19 14 39 86 50 13 62
70 43 74 72 45 41 13 42 87 34
95 33 7 76 39 88 55 64 16 37
24 70 27 78 78 36 85 79 50 15
1 42 24 11 41 78 58 7 51 27
91 26 84 65 71 15 32 95 79 31
100 79 78 99 41 89 12 77 90 48
58 12 65 57 60 52 37 25 71 26
45 98 2 43 82 3 26 52 86 28
21 50 29 23 18 59 79 48 63 97
53 25 43 25 98 79 6 30 89 48
5 51 1 1 36 34 51 17 93 73
35 83 10 62 46 46 82 47 97 46
53 25 29 1 97 7 45 16 62 83
51 24 71 78 75 40 97 97 69 39
35 4 69 90 27 70 16 15 56 96
22 80 64 22 36 66 3 14 81 69
4 54 13 100 97 23 71 46 63 52
8 88 74 93 53 84 2 55 10 2
75 28 66 58 48 87 30 12 83 27
5 35 40 86 85 56 79 20 7 86
13 5 86 97 42 43 21 71 86 70
31 64 50 32 28 86 46 98 2 36
98 67 43 64 41 72 95 83 92 44
6 64 79 7 7 94 92 40 25 88
97 55 34 5 19 89 58 38 82 66
67 43 50 69 37 11 16 79 92 17
16 79 76 21 85 12 67 18 32 68
49 82 70 80 13 44 70 57 27 70
6 83 5 79 15 91 92 29 50 79
81 84 67 96 65 88 82 98 12 30
55 13 37 12 100 57 68 80 27 71
79 51 75 17 89 44 22 34 62 95
7 60 8 51 74 41 84 1 38 82
97 29 35 1 37 65 88 99 45 100
68 29 86 53 36 26 23 83 19 63
26 43 93 34 93 35 17 6 99 55
84 94 30 49 86 7 18 39 54 4
42 23 85 57 84 89 53 25 57 97
56 82 3 62 89 17 6 28 99 26
59 34 22 37 39 24 64 31 5 86
78 88 67 62 23 32 72 65 32 98
97 51 41 90 79 49 16 49 75 78
39 33 93 81 44 4 88 50 19 1
31 97 78 79 17 62 1 69 26 74
39 51 75 63 6 63 31 7 55 24
93 74 34 52 4 26 55 60 27 51
80 41 93 77 33 8 38 89 95 20
34 91 57 9 49 93 62 45 7 62
13 20 20 58 23 16 69 51 15 70
75 58 95 64 9 8 100 60 65 68
30 36 90 61 40 12 19 89 39 34
71 54 65 39 72 94 59 47 24 86
38 78 44 4 59 90 43 100 9 70
70 72 45 7 49 10 21 27 54 43
92 43 19 59 8 91 55 42 23 11
92 16 9 95 61 27 11 5 36 4
89 99 9 46 3 51 38 24 33 63
76 44 97 68 7 19 6 5 58 66
56 12 29 60 65 93 60 21 8 47
67 62 52 39 46 20 82 66 58 1
79 46 32 58 36 71 83 52 40 39
40 1 68 95 2 61 97 54 39 61
46 96 80 77 31 34 12 49 70 96
34 12 85 9 66 69 72 40 83 90
23 33 77 7 2 2 19 80 23 27
59 59 94 24 17 90 11 46 62 32
8 63 64 10 34 41 80 87 45 58
9 27 31 20 25 54 5 13 91 100
91 99 41 92 91 19 30 18 86 8
77 45 7 12 6 57 47 28 83 98
86 100 90 83 1 63 61 64 84 67
13 18 81 23 31 28 35 80 70 59
86 68 83 22 89 64 80 60 12 26
11 79 6 16 40 73 91 36 4 86
69 98 35 16 18 54 88 24 57 41
13 91 85 3 47 50 2 16 61 94
50 88 14 43 47 47 90 15 46 73
14 29 64 78 57 91 27 89 65 24
58 89 69 40 42 5 10 90 97 7
80 86 71 40 15 90 70 18 61 100
22 66 36 51 18 29 14 33 53 55
41 86 87 71 67 93 38 54 44 71
45 66 2 7 87 67 4 45 69 90
43 63 48 88 61 71 20 71 58 32
41 26 17 44 46 100 63 29 24 7
47 37 24 28 75 84 24 96 11 4
30 63 63 77 3 11 68 60 60 52
57 4 41 22 37 31 48 24 53 36
91 83 73 74 6 54 46 32 19 80
8 51 24 19 55 32 8 2 67 19
89 11 58 49 47 38 28 49 39 31
28 34 92 64 34 58 32 14 27 14
31 11 67 64 54 37 90 40 81 97
23 66 74 49 57 66 3 23 17 76
42 84 57 73 25 58 52 26 91 48
63 88 93 15 18 40 35 16 98 26
60 90 18 3 10 84 79 47 67 41
26 36 82 50 80 68 96 82 17 97
98 46 78 59 25 9 28 74 1 62
14 37 30 96 5 76 49 65 52 50
29 43 21 16 65 24 16 82 99 56
67 47 34 84 85 42 95 78 91 97
71 50 68 16 50 17 53 37 33 94
65 100 75 83 59 92 40 73 19 70
24 83 93 88 84 64 85 41 63 49
36 76 57 69 70 52 39 10 16 39
84 84 11 3 80 49 5 24 37 67
1 58 23 46 28 58 84 17 80 4
62 70 91 48 36 56 15 88 39 93
63 37 20 86 24 81 78 89 69 6
31 47 61 93 13 91 62 70 41 3
41 40 59 2 100 33 74 81 81 44
9 66 92 37 83 58 31 4 66 40
14 12 31 77 11 53 7 56 47 7
12 5 79 51 73 41 45 37 15 44
19 28 23 33 4 62 29 27 44 15
53 48 92 63 14 15 52 50 92 43
66 4 10 61 75 62 89 19 47 48
15 11 25 50 14 88 49 16 14 94
3 30 59 11 72 82 26 50 63 41
24 65 32 94 90 63 6 76 15 56
46 95 22 99 54 46 36 63 38 7
4 6 2 96 16 42 51 15 38 59
58 11 42 23 50 40 57 84 62 14
92 36 2 14 22 82 9 61 72 77
46 84 7 72 88 46 64 51 68 71
38 35 22 25 50 83 60 85 94 24
44 97 88 39 57 66 70 97 30 77
67 11 88 12 51 21 40 12 10 37
30 93 97 12 78 55 78 89 6 20
59 36 73 89 67 83 56 62 87 85
26 66 95 46 21 56 46 19 80 14
12 61 50 100 58 92 31 3 37 63
92 30 61 73 2 83 83 55 41 20
87 10 30 39 51 55 34 74 72 58
62 23 62 19 5 96 95 80 4 56
80 63 34 38 75 73 65 62 50 41
93 13 72 10 45 43 66 64 68 9
43 59 89 24 56 64 44 26 47 31
32 29 99 56 63 14 30 28 94 59
7 84 28 77 28 76 27 96 84 6
63 77 16 95 82 15 8 4 41 50
18 46 36 8 63 8 15 28 32 30
94 59 63 65 31 93 16 71 88 3
84 28 95 38 72 50 5 84 15 2
99 80 70 84 97 90 3 93 96 47
85 79 37 69 82 95 100 71 26 58
22 59 5 36 3 39 52 1 45 7
37 48 20 20 40 75 65 42 17 70
88 4 57 79 9 84 2 41 9 13
63 84 25 27 3 4 44 79 55 61
88 82 92 100 100 32 59 7 1 72
67 74 73 32 35 100 22 60 37 62
15 5 10 51 64 23 93 67 3 84
33 60 25 59 91 15 76 44 28 70
16 17 13 92 8 77 38 83 41 91
6 55 98 4 99 58 5 92 23 45
50 68 83 6 32 7 84 77 76 56
3 40 51 87 91 87 50 92 62 81
39 13 30 54 49 1 31 100 16 40
37 56 47 79 51 14 2 55 93 38
51 42 54 3 84 69 53 19 95 95
60 24 100 23 72 92 42 63 99 96
56 50 52 6 49 61 93 86 70 67
57 38 79 52 81 29 93 50 46 53
91 60 83 26 92 63 37 72 38 66
57 5 82 48 26 40 20 7 84 34
85 51 54 75 88 27 35 13 20 28
56 43 30 82 39 9 11 36 50 33
50 30 9 44 38 9 19 25 64 74
59 21 50 94 4 32 36 13 71 60
58 32 44 50 57 98 55 18 18 88
43 46 41 83 59 75 66 65 88 32
2 73 84 3 11 36 69 53 10 33
32 65 21 89 53 90 23 79 75 37
68 46 3 49 96 43 66 16 68 85
21 98 28 28 43 75 15 15 46 97
75 56 15 80 83 32 36 100 78 96
75 10 97 100 60 1 52 42 8 90
64 41 25 55 7 30 61 71 5 68
57 87 40 30 39 55 79 98 85 23
34 56 17 12 94 57 99 20 35 92
6 73 40 42 65 73 22 7 7 99
3 74 60 9 26 83 36 58 66 35
18 96 91 86 93 2 100 15 54 54
22 31 61 93 26 3 67 9 3 38
72 10 27 58 29 28 35 27 68 2
81 15 33 49 62 75 50 5 45 20
37 90 1 77 59 61 73 66 32 39
4 3 84 8 56 20 9 91 72 19
57 97 67 13 41 20 38 39 11 46
79 87 18 8 70 43 40 74 98 73
8 48 25 58 33 53 72 18 12 41
98 27 52 51 8 16 61 6 68 43
31 34 17 4 83 1 60 22 74 33
99 18 98 18 51 87 36 70 19 46
89 100 96 9 25 81 17 67 34 71
89 5 42 37 65 87 48 98 10 82
39 47 28 59 9 22 39 98 65 19
93 8 83 32 57 16 16 71 27 37
24 87 48 65 79 38 7 90 6 23
50 73 76 6 98 65 19 51 78 92
95 13 61 27 56 89 25 88 73 49
5 12 97 43 44 78 72 71 82 28
3 77 14 12 10 13 29 6 30 35
34 93 31 39 85 87 70 67 32 69
2 22 71 10 74 95 96 34 99 53
77 95 88 25 10 67 89 69 42 2
73 11 82 8 78 66 30 97 83 68
45 30 73 36 83 50 28 39 57 91
27 8 26 2 45 59 81 53 1 75
65 78 7 74 71 47 1 30 27 76
79 48 25 70 87 64 15 15 72 32
84 10 61 51 76 97 63 47 53 29
15 100 19 90 16 86 11 76 81 39
47 84 5 91 13 8 39 81 4 61
38 31 51 87 63 27 45 49 50 65
86 93 91 28 46 23 88 85 35 40
2 18 39 47 58 8 15 90 15 32
16 51 66 27 68 38 35 85 43 24
90 100 27 59 4 52 3 43 57 17
50 100 5 12 62 10 44 48 71 75
98 27 76 20 63 11 98 3 100 16
24 10 49 30 29 55 16 28 9 72
72 22 93 40 35 2 82 85 97 87
32 60 39 88 93 51 32 82 69 51
93 51 51 17 89 70 63 68 73 42
51 34 36 50 48 7 7 34 32 16
52 15 62 12 7 66 38 41 87 41
54 11 40 58 23 97 30 5 84 59
43 90 67 21 39 41 13 30 75 20
73 69 83 17 19 16 84 43 31 27
80 18 42 64 31 92 65 83 1 33
20 82 56 87 70 7 74 16 95 60
22 57 67 77 13 42 76 76 89 48
25 22 19 1 2 64 87 74 46 91
65 78 72 3 68 36 88 8 32 71
9 16 94 72 12 82 42 65 93 9
76 14 79 7 33 35 21 24 85 16
99 49 77 14 10 50 64 21 88 100
100 91 83 14 45 6 43 87 6 7
72 55 97 83 7 32 75 92 65 48
56 21 100 94 12 94 24 6 14 83
79 23 10 34 14 47 66 30 97 91
86 86 25 92 19 34 22 52 51 8
22 32 5 74 4 19 3 26 66 68
88 3 86 44 78 43 88 5 38 94
51 54 35 92 35 1 72 78 79 69
33 9 90 16 28 65 6 91 29 41
8 54 21 94 85 70 86 71 1 55
85 63 5 14 72 9 39 98 56 94
34 28 82 89 37 68 86 9 97 62
73 26 6 95 19 27 41 83 90 16
57 35 80 19 43 13 70 22 74 9
32 76 41 47 40 73 65 63 98 15
40 63 60 39 27 18 16 6 19 28
7 51 55 90 20 49 94 56 53 17
38 25 64 36 1 18 78 31 90 51
85 77 22 5 57 15 39 90 19 14
37 35 11 65 31 14 52 19 42 12
35 56 39 15 59 88 100 9 38 72
51 20 88 51 91 14 81 34 27 21
91 8 63 47 72 79 86 48 37 83
42 99 84 81 23 29 16 2 96 28
35 31 4 32 63 94 50 10 95 74
27 71 66 93 74 40 99 13 81 49
59 88 8 78 17 63 6 20 69 68
75 46 39 87 34 73 95 48 44 54
41 19 5 95 71 17 1 90 40 22
11 31 70 14 88 34 26 41 73 23
100 2 10 75 78 3 73 5 25 37
17 61 39 85 83 56 27 95 58 16
13 79 80 1 15 35 94 85 44 59
53 95 53 51 21 88 93 34 27 24
92 22 63 28 60 26 91 1 48 62
26 37 36 79 93 56 75 94 87 58
89 5 79 8 35 38 75 6 94 63
48 1 24 33 27 52 25 19 13 79
35 5 9 64 2 45 80 64 47 74
11 60 47 59 76 77 10 81 3 22
22 35 39 48 4 93 9 84 74 63
91 53 26 36 10 46 67 80 84 42
34 2 63 86 81 17 8 33 79 31
58 29 73 6 5 10 92 65 39 20
54 95 100 81 98 51 36 17 77 22
61 62 3 12 77 12 62 23 90 83
51 22 59 50 50 36 14 35 52 34
35 48 59 87 55 93 88 7 82 96
18 56 13 51 45 14 71 53 31 89
90 19 28 49 60 12 52 46 48 54
26 14 67 63 24 34 94 30 31 1
67 74 10 13 15 92 27 19 19 43
63 87 90 22 41 37 46 25 88 44
32 38 95 69 58 74 11 81 99 50
25 66 66 59 30 19 86 51 6 44
80 95 64 35 84 26 90 96 8 6
96 58 5 46 37 11 18 32 63 71
68 88 10 83 19 26 36 84 78 48
7 42 29 55 37 95 65 59 47 95
Selecting aa Range
Selecting Range That
That Fits
Fits on
on the
the Screen
Screen

In Excel,
In Excel, you
you usually
usually select
select aarange
range andandthen
then do do something
somethingto to itit (such
(such as as enter
enter aa
formula in it, format it, delete its contents, and so on). Therefore,
formula in it, format it, delete its contents, and so on). Therefore, it is extremely it is extremely
important to
important to be
be able
abletoto select
select aarange
rangeefficiently.
efficiently.This
This isis easy
easy ifif the
the whole
whole range
range
appears on
appears on the
thescreen,
screen, but
butits
its aabit
bit trickier
trickier ifif you
you cant
cant see
seethethewhole
whole range.
range. In
In
thelatter
the latter case
casethethe effect
effect ofof dragging
dragging (the (themethod
method most most users
users try)
try) can
canbe be
frustratingthings scroll
frustratingthings scroll by
by too
too quickly--you
quickly--you scrollscroll too
too far,
far, then
thennot not far
far enough,
enough,
andso
and so on.
on.Try
Try one
one ofof the
the methods
methods below below instead.
instead.

To select
To select aarange
rangethat
that fits
fits on
on aascreen:
screen:

Click the
Click the upper
upper left
left cell
cell of
of the
therange
rangeand
and drag
dragto
to the
the bottom
bottom right
right cell.
cell.

Or:
Or:
Click the
Click the upper
upper left
left cell,
cell, hold
hold down
downthe
the Shift
Shift key,
key, and
and click
click the
the bottom
bottom right
right cell.
cell.

Tryit!
Try it! Select
Selectthe
the blue
bluerange
rangeto
to the
the right.
right.

Selecting aa Range
Selecting Range That
That Doesn't
Doesn't Fit
Fit on
on the
the Screen
Screen

To avoid
To avoid the
theendless
endless scrolling
scrolling that
that many
manypeople
people use
useto
to select
select aalarge
largerange,
range, you
you
can use either of the following methods.
can use either of the following methods.
Click the
Click the upper
upper left
left cell
cell of
of the
therange.
range. Then,
Then, holding
holding the
the Shift
Shift key
keydown,
down, use
use the
the
End-arrow combinations
End-arrow combinations (End-right
(End-right arrow,
arrow, then
then End-down
End-down arrow
arrow or
or vice
vice versa)
versa) to
to
get to the bottom right cell.
get to the bottom right cell.
Or:
Or:
Split the
Split the screen
screenso so that
that the
the upper
upper left
leftcell
cell shows
shows in
in the
the upper
upper left
left pane
pane and
and the
the
bottom right
bottom right cell
cell shows
showsin inthe
the bottom
bottom right
rightpane.
pane.Click
Click the
the upper
upper left
left cell,
cell, hold
hold
theShift
the Shift key
key down,
down, andand click
click the
thebottom
bottom right
rightcell.
cell.

Tryit!
Try it! Select
Selectthe
the red
red range
range to
to the
the right.
right.Try
Tryboth
both of
of the
themethods
methods suggested
suggested here.
here.
9 2 10
1 3 8
8 1 10
7 5 4
5 1 1
5 10 7

63 61 4 36 45 85 91 23 17 76
52 95 40 75 28 67 79 75 49 76
18 98 47 28 65 17 86 23 63 73
25 21 7 68 16 12 80 87 59 29
26 76 55 60 55 19 82 61 42 44
42 52 72 79 16 14 85 49 81 7
14 29 75 36 52 75 17 33 66 50
87 41 48 22 25 77 3 57 32 3
100 71 10 11 90 15 62 24 83 66
59 51 90 35 94 83 77 26 79 61
43 72 53 21 60 22 33 67 29 71
19 73 49 38 33 42 49 84 8 49
86 58 55 59 41 63 75 19 34 37
7 62 41 62 26 17 95 97 79 98
52 78 37 18 45 98 35 40 73 72
18 32 62 79 86 31 58 3 14 26
1 89 92 86 88 94 12 49 38 52
71 71 58 14 37 27 73 31 83 28
75 18 70 77 52 6 45 8 57 78
2 5 21 95 16 8 66 82 72 87
64 89 38 32 8 51 63 86 1 91
64 67 81 11 34 16 30 16 39 65
6 30 42 3 68 27 12 86 77 24
87 78 33 53 48 86 17 4 61 4
64 64 15 28 44 65 29 10 57 92
58 33 81 90 48 26 55 49 34 23
76 54 84 66 65 78 3 88 17 97
15 79 47 71 19 74 58 63 57 4
73 85 20 100 6 46 17 24 86 49
43 40 26 30 59 98 46 85 23 75
83 54 38 91 59 27 82 98 39 91
41 85 63 28 29 59 47 76 81 24
55 72 42 24 59 41 78 1 53 7
23 22 17 76 50 67 17 6 97 74
54 74 23 86 88 85 98 79 83 51
81 54 24 61 41 43 13 44 91 18
16 86 24 58 99 49 50 93 65 88
31 38 91 46 44 15 23 12 32 70
47 67 39 26 54 85 65 52 4 57
69 4 10 56 89 66 13 99 22 10
82 28 25 20 88 92 28 97 42 65
66 69 81 19 78 100 57 27 52 80
19 85 32 47 1 69 68 16 19 28
58 30 88 16 44 90 9 91 68 87
8 98 6 1 74 2 53 35 85 80
4 22 18 11 61 5 100 43 49 34
22 89 29 84 88 18 67 12 26 34
5 81 48 65 9 67 13 78 55 36
33 95 12 21 18 73 31 17 85 97
57 32 94 59 15 22 18 77 4 84
67 55 5 66 36 26 34 82 59 8
4 10 12 86 91 11 73 14 28 67
52 69 35 8 38 63 20 68 16 64
46 25 70 45 99 56 34 4 98 77
79 71 61 38 37 66 24 97 91 44
28 51 23 75 42 89 79 42 22 58
95 41 44 60 83 57 61 59 39 9
40 76 54 4 46 23 28 66 29 76
96 61 55 1 59 67 37 96 52 95
3 7 17 28 87 5 98 31 62 72
96 37 82 70 8 56 25 41 16 72
39 33 1 82 35 51 71 55 66 43
46 15 81 86 74 69 22 85 64 69
23 24 3 40 30 27 73 16 85 2
6 64 5 95 11 15 90 36 44 97
72 36 24 58 23 89 45 83 68 65
8 34 69 26 14 77 15 8 21 71
48 91 81 13 94 87 18 48 63 29
70 29 30 5 18 75 97 27 62 76
57 78 44 99 59 65 31 91 38 13
98 92 39 60 45 75 30 34 53 95
45 23 30 91 89 36 9 64 11 54
69 70 86 55 70 5 78 71 51 70
50 56 42 18 47 2 85 49 53 17
17 20 19 68 2 10 2 12 79 67
55 56 25 28 1 71 64 8 7 23
64 68 99 77 20 38 29 96 6 92
87 77 77 13 85 62 4 66 11 95
96 72 80 61 73 72 86 49 79 89
49 49 44 70 31 67 78 20 98 47
61 77 11 51 34 31 56 61 83 33
21 16 58 34 98 16 16 3 76 5
27 56 14 91 25 91 6 63 35 98
69 9 80 23 78 100 6 96 47 41
25 30 92 61 71 26 85 93 71 55
33 13 51 65 39 29 26 41 17 65
57 3 79 32 66 4 18 40 62 45
47 88 15 53 21 64 70 1 78 81
84 100 79 8 5 42 12 28 95 25
56 28 72 4 48 24 95 93 61 92
97 11 80 93 63 95 86 51 19 2
84 29 81 94 78 9 7 89 73 42
6 20 53 54 18 4 82 59 48 62
63 10 72 6 36 30 88 50 5 57
15 87 60 88 86 45 36 76 98 59
54 16 18 26 17 24 26 34 94 59
3 11 85 63 41 71 15 42 87 85
24 41 43 29 67 82 62 63 14 59
85 64 24 24 49 30 78 73 44 70
68 20 2 43 85 42 58 20 43 73
51 49 14 73 98 20 67 33 84 7
87 38 25 46 61 68 17 26 43 20
59 86 33 25 95 28 55 17 6 92
91 96 93 29 54 7 56 2 38 88
15 74 17 57 89 12 64 28 100 76
53 7 40 45 83 35 76 57 8 24
83 8 31 50 96 96 33 80 20 14
11 52 3 58 61 34 51 43 90 73
83 37 53 99 90 65 91 21 95 48
77 31 75 6 72 36 39 51 25 72
49 12 36 47 54 76 39 22 5 30
65 34 60 47 82 72 33 20 74 52
84 32 10 84 74 22 10 26 39 64
6 88 15 60 13 17 92 71 45 45
59 20 62 17 80 12 17 78 96 55
8 30 73 2 52 71 29 21 41 59
22 27 1 50 3 15 13 41 71 13
1 79 98 30 14 12 63 11 54 41
18 90 45 74 53 80 71 3 35 74
45 72 47 25 73 82 45 29 39 100
9 78 17 35 52 54 93 74 77 66
71 63 73 18 49 41 19 11 42 49
24 38 39 66 100 74 73 12 87 42
71 49 91 9 29 46 57 47 10 98
10 76 40 93 79 81 33 7 97 43
18 86 17 49 63 39 11 36 23 63
53 17 97 64 53 44 53 28 85 29
86 25 77 59 36 86 43 73 23 68
63 99 36 53 34 59 36 36 61 84
48 60 41 33 53 1 99 83 15 65
95 47 63 73 89 94 98 4 33 90
58 75 86 75 87 12 86 60 9 93
70 92 42 91 29 47 1 6 61 53
29 57 83 93 81 40 15 68 41 45
99 92 40 22 35 2 22 16 75 16
7 62 71 50 62 16 12 49 28 73
37 22 59 66 40 58 66 14 77 3
10 74 12 13 94 72 74 86 71 33
52 32 71 18 55 72 48 65 84 87
94 49 11 94 84 79 37 61 48 32
20 5 77 86 5 19 71 53 94 65
17 99 90 76 84 14 2 41 63 23
20 44 68 34 47 77 75 8 15 98
99 41 50 82 67 13 72 40 99 95
48 77 13 71 63 5 32 53 14 40
64 93 34 51 48 55 4 36 28 63
16 6 60 50 91 58 50 74 27 69
3 18 66 54 58 74 33 95 84 63
35 9 85 46 78 100 79 62 86 36
70 8 93 88 42 64 8 96 51 12
8 68 10 100 42 10 42 28 52 74
48 77 78 55 91 47 41 83 94 91
51 67 58 70 51 87 24 24 86 36
93 73 40 50 46 24 40 58 83 53
15 42 28 56 33 99 10 30 73 51
60 90 85 83 53 39 66 37 79 6
99 57 13 74 28 33 70 22 90 29
52 100 9 74 100 64 46 37 32 98
88
24
25
67
50
67
93
4
16
63
70
50
37
76
27
65
13
55
91
99
71
71
49
45
87
42
76
56
25
61
97
98
1
41
25
79
69
78
43
24
75
50
3
30
82
44
37
8
25
37
56
51
6
31
67
8
5
54
36
26
35
73
37
5
25
69
100
5
60
45
13
95
46
54
94
16
95
78
10
Selecting Multiple
Selecting Multiple (Discontiguous)
(Discontiguous) Ranges
Ranges

Suppose you
Suppose you want
wanttoto format
format more
more than
than one
onerange
rangeinin aa certain
certain way
way (as
(as currency,
currency,
for example). The quickest way is to select all ranges at once and then
for example). The quickest way is to select all ranges at once and then format format
themall
them all at
at once.
once.

To select
To select more
more than
than one
onerange:
range:

Select the
Select the first
first range,
range, press
press the
the Ctrl
Ctrl key,
key, select
select the
the second
secondrange,
range, press
press the
the Ctrl
Ctrl
key, select
key, select the
the third
third range,
range, and
and soso on.
on.

For example,
For example, toto select
select the
the ranges
ranges K4:L6
K4:L6 and
and N4:O8,
N4:O8, click
click cell
cellK4,
K4, hold
holddown
downthe
the
Shiftkey
Shift key and
and click
click cell
cell L6
L6(so
(sonow
now the
the first
first range
range isis selected),
selected), hold
holddown
down the
the Ctrl
Ctrl
key and
key andclick
click cell
cell N4,
N4, and
andfinally
finallyhold
hold down
down the the Shift
Shiftkeykeyand
andclick
click cell
cell O8.
O8.
Tryit!
Try it! Select
Selectall
all three
threenumerical
numericalranges
rangesto
to the
the right.
right.

Notethat
Note that in
in Excel
Excel 2007,
2007, the
the selecting
selecting isis sometimes
sometimeshard hardtoto see.
see.The
The shading
shadingisnt
isnt
as dark
as dark as
as in
in previous
previous versions
versions ofof Excel,
Excel, so
so you
you might
might be befooled
fooledinto
into thinking
thinkingyou
you
havent really
havent reallyselected
selected multiple
multiple ranges.
ranges.ButBut the
the above
above method
methoddefinitely
definitelyworks,
works,
exactly as
exactly as ititalways
alwayshas.
has. (This
(This problem
problemwas wasfixed
fixed in
in Excel
Excel 2010.
2010.TheTheshading
shadingisis now
now
much more
much moreapparent.)
apparent.)
10 13 7 9
1 9 12 7
5 4 1 1
6 12
15 2

13 4 10
Go To
Go To aa Cell
Cell

TheF5
The F5key
keyisiscalled
called the
the "Go
"Go To"
To" key.
key.When
Whenyouyou press
press it,
it, you
youcan
can type
type in
in any
any cell
cell
address (or range name) and press Enter. You go immediately to that cell
address (or range name) and press Enter. You go immediately to that cell (or that (or that
named range).
named range).

Tryit!
Try it! Use
Usethe
theGoGo To
Tokey
keytoto go
go directly
directly to
to cell
cell X100.
X100. (Then
(Then press
press Ctrl+Home
Ctrl+Home to
to
return to cell A1 so that you can do the next exercise
return to cell A1 so that you can do the next exercise below.) below.)

Go To
Go To Special
Special Options
Options

The F5
The F5 key
key isis actually
actually much
much more
more flexible
flexible than
thanindicated
indicated above.
above. IfIf you
you press
press F5
F5 and
and
then click
then click the
the Special
Special button,
button, you
youcan
can"go "go to"
to" (that
(that is,
is, select)
select) aa number
number of of different
different
things. For
things. For example,
example, you you can
can select
select aa range,
range, press
press F5,
F5, and
and select
select Blanks
Blanks from
from the
the
Special group (see the screenshot to the right). All of the blanks
Special group (see the screenshot to the right). All of the blanks in the range arein the range are
then selected.
then selected. The The following
following exercise
exercise shows
shows how
how useful
useful this
this can
can be.
be.

The blue
The blue range
range to to the
the right
righthas
has aa lot
lot of
of missing
missing values,
values, and
andthe
the goal
goal isisto
to fill
fill them
them in
in
the obvious way. You could start dragging down, but there is a much
the obvious way. You could start dragging down, but there is a much easier way easier way
(especially ifif this
(especially this example
example were
were much
much larger).
larger).

1. Select
1. Selectthe
the entire
entire blue
blue range.
range.
2. Press F5, click the Special button, and
2. Press F5, click the Special button, and select
select Blanks.
Blanks. This
This selects
selects all
all the
the blank
blank
cells.
cells.
3. Enter
3. Enter an
an equals
equals sign
sign (=),
(=), press
press the
the up
up arrow
arrow key,
key, and
and press
press Ctrl+Enter.
Ctrl+Enter.

Do you
Do you see
see what
what happened?
happened?Each Each blank
blank cell
cell now
now has
hasaa formula
formula that
that makes
makes itit equal
equal
to the
to thecell
cell above
above it,
it, so
so all
all of
of the
the labels
labelsare
are effectively
effectivelycopied
copied down.
down.

There are
There are many
many other
otheroptions
options in
in the
the Go
GoTo
To Special
Special dialog
dialog box.
box. One
One common
common option
option
when you want to delete (or move) a number of text boxes on a sheet.
when you want to delete (or move) a number of text boxes on a sheet. Then you Then you
canchoose
can choosethe
the Objects
Objects option
option toto select
selectall
all of
of the
the text
textboxes
boxes (as
(as well
well as
as other
other
objects, such
objects, such as
asarrows
arrows oror rectangles,
rectangles, that
that might
mightbe be on
onthe
the sheet).
sheet).You
You can
can
experiment with
experiment with this
this and
and other
other options.
options.
Jan Q1 2009

Feb

Mar

Apr Q2

May

Jun
Copying, Cutting,
Copying, Cutting, and
and Pasting
Pasting

Muchof
Much of the
the real
real power
power ofof Excel
Excel comes
comes from
from the
the ability
ability to
to copy
copy andand paste
paste(or
(or cut
cut
and paste). This is especially true for copying and pasting formulas.
and paste). This is especially true for copying and pasting formulas. The next few The next few
sheets illustrate
sheets illustrate efficient
efficient ways
ways to
tocopy
copy and
and paste
paste(or (or cut
cut and
and paste).
paste). As
As with
withthe
the
previous"Moving,
previous "Moving, Selecting"
Selecting" topic,
topic, the
thetips
tips in
in this
this section
section will
will improve
improve your
your
efficiency dramatically.
efficiency dramatically.
General Copying
General Copying and
and Pasting
Pasting Comments
Comments

Copying and
Copying andpasting
pasting (often
(often formulas)
formulas) isis one
one ofof the
the most
most frequently
frequently done done tasks
tasks in
in Excel,
Excel, and
and itit can
can be
be aa
real time-waster if it is done inefficiently. For example, many people scroll through
real time-waster if it is done inefficiently. For example, many people scroll through a long range to a long range to
select it,
select it, then
then click
click on
onthetheCopy
Copy button
button or or aa Copy
Copy menu
menuitem,
item, thenthen scroll
scroll again
againtoto select
select aapaste
paste range,
range,
and finally
and finally click
click on
on the
the Paste
Pastebutton
button or
or aa Paste
Paste menu
menu item.
item. IfIf this
this sounds
sounds familiar,
familiar, you
you can
can definitely
definitely
benefit from
benefit from thethe tips
tips here.
here. Actually,
Actually, there
there are
are several
several possibilities
possibilities forfor efficient
efficient copying
copying andand pasting,
pasting, as as
explained below.
explained below.

Copying and
Copying and Pasting
Pasting with
with Keyboard
KeyboardShortcuts
Shortcuts

To copy
To copy and
and paste
paste using
using keyboard
keyboard shortcuts:
shortcuts:

Selectthe
Select the copy
copyrange
range (using
(using one
oneof of the
the efficient
efficientselection
selectionmethods
methods described
described on onthe
the previous
previous two
two
sheets), press
sheets), press Ctrl+c
Ctrl+c (for
(for copy),
copy), select
select the
the paste
paste range
range (again,
(again, efficiently),
efficiently), and
and press
press Ctrl+v
Ctrl+v (for
(for paste).
paste).
IfIf you
you practice
practice pressing
pressing Ctrl+c
Ctrl+c or
or Ctrl+v
Ctrl+vwith
with the
the little
little finger
finger and
and index
index finger
finger of
of your
your left
left hand,
hand, itit will
will
becomeautomatic
become automatic inin aashort
short time.
time.

Yes, you
Yes, you can
can click
click the
theCopy
Copy and
and Paste
Paste buttons
buttons on
onthe
the Home
Home ribbon,
ribbon, but
but the
the keyboard
keyboard shortcuts
shortcuts are
are
faster. Besides,
faster. Besides, they
they work
work on
on virtually
virtually all
all Windows
Windows programs,
programs, not
not just
just Excel.
Excel.

Notethat
Note that the
thecopy
copy range
range will
will still
still have
have aadotted
dottedline
linearound
around it,
it, which
which means
means that
that itit isis still
still stored
stored on
on
theclipboard.
the clipboard. Press
Press the
the Esc
Esc key
keyto to get
getrid
rid of
of this
this dotted
dottedline.
line.

Try it!
Try it! Copy
Copythe
theformula
formula in
in the
the darker
darker red
red cell
cell down
downthrough
through the
the rest
rest of
of the
the red
red range
range using
usingCtrl+c
Ctrl+c and
and
Ctrl+v.
Ctrl+v.

Using Ctrl+Enter
Using Ctrl+Enter Shortcut
Shortcut

AA frequent
frequenttask
task isis to
to enter
enter aaformula
formula in inone
one cell
cell and
and copy
copy itit down
downaa column
columnor
or across
across aarow.
row.There
There are
are
several very
several very efficient
efficientways ways to
to do
do this.
this.

Oneway
One way isis to
tosimulate
simulatecopying
copyingand
and pasting
pasting with
with Ctrl+Enter:
Ctrl+Enter:

Starting with
Starting with the
thetop
top or
or left
leftcell,
cell, select
select the
the range
range where
where the theresults
results will
will go.
go.(Use
(Use the
the efficient
efficient selection
selection
methods described
methods described earlier,
earlier, especially
especially ifif this
this range
rangeisisaa big
big one.)
one.) Type
Type the
the formula,
formula, and
and press
press Ctrl+Enter
Ctrl+Enter
(both keys
(both keysat
at once)
once) instead
insteadof of Enter.
Enter.

Try it!
Try it! Fill
Fill the
the blue
blue range
range with
with Ctrl+Enter.
Ctrl+Enter.Each
Each cell
cell should
shouldbe
be the
theproduct
productof
of the
the two
two values
values to
to its
its left.
left.

Pressing Ctrl+Enter
Pressing Ctrl+Enter enters
enters what
what you
you typed
typed in
in all
all of
of the
theselected
selectedcells
cells (adjusted
(adjusted for
for relative
relative addresses),
addresses),
so in general, it can be a real time-saver. For example, it can be used to enter the
so in general, it can be a real time-saver. For example, it can be used to enter the number 10 in number 10 in aa
wholerange
whole range of
of cells.
cells. Just
Just select
select the
therange,
range, type
type 10,
10, and
and press
press Ctrl+Enter.
Ctrl+Enter.

Try it!
Try it! Fill
Fill up
upthe
the green
greenrange
rangewith
with the
the value
value10
10 by
by using
using Ctrl+Enter.
Ctrl+Enter.
Try it!
Try it! Fill
Fill the
the blue
blue range
range with
with Ctrl+Enter.
Ctrl+Enter.Each
Each cell
cell should
shouldbe
be the
theproduct
productof
of the
the two
two values
values to
to its
its left.
left.

Pressing Ctrl+Enter
Pressing Ctrl+Enter enters
enters what
what you
you typed
typed in
in all
all of
of the
theselected
selectedcells
cells (adjusted
(adjusted for
for relative
relative addresses),
addresses),
so in
so in general,
general, itit can
can be
be aa real
real time-saver.
time-saver.For
For example,
example, itit can
can be
be used
usedto to enter
enter the
the number
number 10 10 in
in aa
whole range of cells. Just select the range, type 10, and press
whole range of cells. Just select the range, type 10, and press Ctrl+Enter. Ctrl+Enter.

Try it!
Try it! Fill
Fill up
upthe
the green
greenrange
rangewith
with the
the value
value10
10 by
by using
using Ctrl+Enter.
Ctrl+Enter.

Dragging the
Dragging the AutoFill
AutoFill Handle
Handle

IfIf you
you place
place the
thecursor
cursor at
atthe
the bottom
bottom right
right of
of aacell,
cell, the
the cursor
cursor becomes
becomes aa plus
plus sign.
sign. This
Thisisiscalled
called the
the
AutoFill handle. To copy a formula down, you can use the AutoFill handle in two different
AutoFill handle. To copy a formula down, you can use the AutoFill handle in two different ways. Here ways. Here
isis the
the first.
first.

To copy
To copy with
withthe
the AutoFill
AutoFill handle
handle by
by dragging:
dragging:

Enter the
Enter the formula
formulain
in the
thetop
top oror left-hand
left-hand cell
cell of
of the
the intended
intended range.
range.Place
Place the
thecursor
cursor on
on the
the AutoFill
AutoFill
handle at
handle atthe
thelower
lower right
rightof
of this
thiscell
cell (the
(the cursor
cursor becomes
becomes aa plus
plussign),
sign), and
and drag
dragthis
this handle
handle down
down or
or
acrossto
across to copy.
copy.

Try it!
Try it! Copy
Copythe
theformula
formula in
in the
the darker
darker orange
orange cell
cell down
down through
throughthe
the rest
rest of
of the
theorange
orangerange
rangewith
with the
the
AutoFill handle.
AutoFill handle.

Double-Clicking the
Double-Clicking the AutoFill
AutoFill Handle
Handle

The second
The second way
wayto
to copy
copy down
down isis to
to double-click
double-click the
the AutoFill
AutoFill handle.
handle.

This method
This method usesuses Excels
Excels built-in
built-in intelligence,
intelligence, but
butititworks
works only
only in in certain
certain situations.
situations.Lets
Lets say
say you
you have
have
numbers in
numbers in the
therange
rangeA3:B100.
A3:B100. You
You want
wantto to enter
enter aaformula
formulain incell
cell C3
C3 and
and copy
copy itit down
downto to cell
cell C100.
C100.
Becausethis
Because this isis aacommon
commonthingthing toto do,
do, Excel
Excel does
does itit for
for you
you ifif you
you double-click
double-click thethe AutoFill
AutoFill handle.
handle. ItIt
senses the
senses thefilled-up
filled-up rangerange in
in column
column BBand and guesses
guesses that thatyou
youwant want another
another filled-up
filled-up range
range right
rightnext
next
to it in column C. If there were no adjacent filled-up range, double-clicking
to it in column C. If there were no adjacent filled-up range, double-clicking the autofill handle the autofill handle
wouldntwork.
wouldnt work. Also,Also, suppose
suppose there
there isis aamissing
missingvalue
value(a (ablank)
blank) in in cell
cell B56.
B56.Then
ThenAutoFill
AutoFill will
will copy
copy
down only
down onlytoto cell
cell C55.
C55.
Try it!
Try it! Copy
Copythe
theformula
formula in
in the
the darker
darker tan
tancell
cell down
down through
through the
the rest
rest of
of the
thetan
tan range
range by
by double-
double-
clicking the
clicking theautofill
autofill handle.
handle.
nn Excel,
Excel, and
and itit can
can be
be aa
ugh a long range
ugh a long range to to
oo select
select aapaste
paste range,
range,
ar, you can
r, you can definitely
definitely
opying and
opying and pasting,
pasting, as as

3 3 9
4 1
2 3
nnthe
the previous
previous two
two 2 1
ress Ctrl+v
ress Ctrl+v (for
(for paste).
paste). 5 1
your left
your left hand,
hand, itit will
will
4 2
3 5
board shortcuts are
oard shortcuts are

at
t itit isis still
still stored
stored on
on

range using
range usingCtrl+c
Ctrl+c and
and

6 2
9 1
cross aarow.
cross row.There
There are
are
4 9
7 6
2 3
the efficient
the efficient selection
selection 8 5
a, and
a, and press
press Ctrl+Enter
Ctrl+Enter 3 9

two values
two values to
to its
its left.
left.

or relative
or relative addresses),
addresses),
he number 10
e number 10 in in aa
two values
two values to
to its
its left.
left.

or relative
or relative addresses),
addresses),
he number 10
e number 10 in
in aa

10 7 70
6 9
ign. This
ign. Thisisiscalled
called the
the
o different ways. Here 4 9
o different ways. Here
5 1
2 8
8 10
ursor on
ursor on the
the AutoFill
AutoFill 10 7
this handle
this handle down
down or
or

orangerange
orange rangewith
with the
the

7 8 56
2 1
10 2
ons.Lets
ons. Lets say
say you
you have
have 4 1
itit down
downtoto cell
cell C100.
C100. 4 5
he AutoFill
he AutoFill handle.
handle. ItIt
ed-up range
ed-up range right
rightnext
next 3 8
autofill handle
autofill handle 7 8
nAutoFill
AutoFill will
will copy
copy

range by
range by double-
double-
Pasting as
Pasting as Values
Values

Often you
Often you have
have aarange
rangeof
of cells
cells that
that contains
contains formulas,
formulas, and
and you
you would
wouldlike
like to
to
replace the formulas with the values they produce. Usually, you
replace the formulas with the values they produce. Usually, you paste these paste these
values onto
values onto thethecopy
copyrange,
range, that
that is,
is, you
youoverwrite
overwrite the
the formulas
formulas with
with values.
values.
However, ititisisalso
However, also possible
possible to
toselect
select another
another range
range for
for the
the paste
pasterange.
range.

To copy
To copyformulas
formulas and
andpaste
paste as
as values:
values:

Select the
Select the range
range with
withformulas,
formulas, press
press Ctrl-c
Ctrl-c to
to copy,
copy, and
and select
selectthe
the range
range where
where
you want
you want totopaste
paste the
the values
values(which
(which can
canbebe the
thesame
sameasas the
the copy
copyrange).
range). Then,
Then,
because there is no keyboard equivalent, select the Paste dropdown
because there is no keyboard equivalent, select the Paste dropdown on the on the
Home ribbon,
Home ribbon, and
and select
selectthe
the Paste
Paste Values
Valuesoption.
option.

Tryit!
Try it! Copy
Copy the
the red
redrange
range to
tothe
the right
right to
to itself,
itself, but
butpaste
paste as
as values.
values.

General Comments
General Comments About
About Paste
Paste Special
SpecialOptions
Options

ThePaste
The Paste dropdown
dropdown on on the
the Home
Home ribbon
ribbon (see
(see to
to the
the right)
right) has
has aa number
number ofof
other "special" ways to paste. Useful options include (1) Paste formulas
other "special" ways to paste. Useful options include (1) Paste formulas (not (not
formats), (2)
formats), (2) Paste
Paste formats,
formats, and
and (3)
(3) Paste
Pastearithmetic
arithmetic operations
operations (the
(thelatter
latter two
two
visible when
visible when you
you click
clickPaste
Paste Special).
Special).

Thefollowing
The following text
text boxes
boxes let
let you
you explore
explorethese
theseoptions.
options.We
We encourage
encourage you
you to
to
explorethe
explore the other
other paste
paste special
special options
options as
aswell.
well.

Notethat
Note that Paste
Paste dropdown
dropdown list
list looks
looks different
differentin
inExcel
Excel 2010,
2010, as
as shown
shown farther
farther to
to
the right. These icons can be confusing, but you can hover the mouse
the right. These icons can be confusing, but you can hover the mouse over any over any
icon to
icon to see
see its
itspurpose.
purpose.

Pasting Formulas
Pasting Formulas Only,
Only, Not
Not Formats
Formats

Sometimesyou
Sometimes youwant
want to topaste
paste formulas
formulas to toaa range,
range, but
but you
you don't
don'twant
want to
to change
change
theformatting
the formatting ofof the
the paste
paste range.
range. YouYou can
can do
do this
this with
with the
the above
above Formulas
Formulas
option(Excel
option (Excel 2007)
2007) or or the
the ffxx icon
icon in
in the
the Paste
PasteSpecial
Special palette
palette (Excel
(Excel 2010).
2010).(The
(The
icon to the right of the f icon in Excel 2010 is for pasting formulas
icon to the right of the fxx icon in Excel 2010 is for pasting formulas and number and number
formats.)
formats.)
Tryit!
Try it! Column
ColumnM M to
to the
the right
right contains
contains formulas.
formulas. Paste
Paste these
these formulas
formulas to
to column
column
O, but
O, but don't
don'tpaste
paste the
theformats.
formats.
Tryit!
Try it! Column
ColumnM M to
to the
the right
right contains
contains formulas.
formulas. Paste
Paste these
these formulas
formulas to
to column
column
O, but don't paste the formats.
O, but don't paste the formats.

Pasting Formats
Pasting Formats Only
Only

Sometimesyou
Sometimes youwant
want to
tocopy
copy only
only the
the formatting
formattingof
of aarange.
range.

To copy
To copythe
theformatting
formatting ofof aa range,
range, select
select the
therange,
range, press
press Ctrl-c,
Ctrl-c, select
selectthe
the paste
paste
range, and
range, and select
select Formats
Formats from
from Paste
Paste Special
Special on
on the
thePaste
Pastedropdown.
dropdown. You You get
get the
the
dialog box to the right (which has only one minor change in Excel
dialog box to the right (which has only one minor change in Excel 2010.) 2010.)

Tryit!
Try it! Copy
Copy the
the formats
formats in
incolumn
columnPP to
to column
column R.
R. (Don't
(Don't copy
copy the
thevalues,
values, just
just the
the
formats.) Then
formats.) Then enter
enter some
some values
valuesin
incolumn
column RRto
to check
check that
that the
the formatting
formatting isis
correct.
correct.
Aneasy
An easyalternative
alternative totothis
this method
methodisis to
to use
use the
the Format
Format Painter
Painter button
button next
next to
to
thePaste
the Pastedropdown
dropdown(see (see to
tothe
the right).
right). Just
Just select
select aacell
cell with
withthe theformat
format you
youwant
want
to copy,
to copy, click
click on
on the
the paint
paint brush,
brush, and
andclick
click on
onaa cell
cell (or
(or drag
drag aarange)
range) that
that you
you
want to
want to format.
format. Note
Note that
that ififyou
you double-click
double-click ononthe
the paint
paint brush,
brush, you you can
can copy
copythe
the
format multiple
format multiple times.
times. Click
Click on
on Esc
Esc when
whenyou youarearefinished.
finished. Once
Once you you get
get
comfortableusing
comfortable using this
this"paint
"paint brush,"
brush," you
you will
will probably
probably use use itit constantly.
constantly.

Multiplying (or
Multiplying (or Adding,
Adding, Subtracting,
Subtracting, Dividing)
Dividing) by
by aa Constant
Constant

Sometimesyou
Sometimes youwould
would like
liketo
to multipy
multipy each
eachnumber
number ininaa range
range by
by aaconstant.
constant. For
For
example, if you have revenues expressed in thousands of dollars, you
example, if you have revenues expressed in thousands of dollars, you might wantmight want
to multiply
to multiply each
eachby
by 1000
1000 so
so that
that they
they are
are then
then expressed
expressedin indollars.
dollars.

To multiply
To multiply aarange
range by
by aaconstant:
constant:

Enter the
Enter theconstant
constant in
in aablank
blank cell,
cell, and
and copy
copy this
this cell.
cell. Then
Thenselect
selectthe
therange
rangeof
of
values to
values to multiply
multiply and
and select
select Multiply
Multiplyfrom
from Paste
Paste Special
Special onon the
thePaste
Pastedropdown.
dropdown.
(This same
(This same method
methodcan canalso
also be
beused
used to
to add,
add, subtract,
subtract, oror divide
divide by
byaa constant.)
constant.)

Tryit!
Try it! Multiply
Multiply each
each value
value in
in the
theblue
blue range
range to
to the
theright
right by
by1000.
1000. Then
Thenrestore
restore
themto
them to their
their original
original values
values by
by dividing
dividingeach
each value
valuebyby1000.
1000. Notice
Notice that
that no
no
formulas are
formulas areinvolved;
involved; the
the numbers
numberssimply
simplychange.
change.
1 1 1
2 3 6
9 5 45
7 4 28
8 8 64
8 10 80
7 6 42

Excel 2007 Excel 2010 (Excel 2013 is similar)

10 2 20
6 7 42
1 8 8
$47.65
$44.20
$37.68
$31.34
$89.36
$68.15
$28.57

147
173
217
178
120
203
137
217
153
Transposing aa Range
Transposing Range (from
(from columns
columns to
to rows
rows or
orvice
vice versa)
versa)

Often you
Often you set
set up
up aa spreadsheet
spreadsheet and
and then
thendecide
decide thatthat you
you would
would rather
rather have
haveaa
portion of it transposed. That is, you would like to turn it on its side,
portion of it transposed. That is, you would like to turn it on its side, so thatso that
rows become
rows becomecolumns
columns and
andvice
viceversa.
versa.This
This isis simple
simple with
withone
one of
of Excels
Excels Paste
Paste
options.
options.
To transpose
To transposeaa range:
range:

Select aarange
Select range that
that you
you want
want toto transpose
transpose andand press
press Ctrl+c
Ctrl+c to
to copy
copy it.
it. Then
Then select
select
theupper
the upper left
leftcell
cell of
of the
the range
rangewhere
whereyou youwant
want the
the transposed
transposed version
versionto to go,
go,
select the
select thePaste
Pastedropdown,
dropdown, and and select
select the
the Transpose
Transpose option
option (see
(see to
to the
the right).
right).

Make sure
Make surethere
there isis enough
enough room
room forfor the
the transposed
transposedversion.
version. ForFor example,
example, ifif the
the
original range
original range has
has 33 rows
rows and
and 55 columns,
columns, the the transposed
transposed version
version will
will have
have 55rows
rows
and33 columns.
and columns. IfIf you
you select
select cell
cell D5,
D5, say,
say, as
as the
the upper
upper left
left cell
cell for
for the
the transposed
transposed
version, everything
version, everythingin in the
therange
range D5:F9
D5:F9 will
will be
be overwritten
overwritten byby the
the transposed
transposed
version.
version.
Tryit!
Try it! Transpose
Transpose the
the blue
bluerange
rangeto
to the
theright
right to
to aarange
range with
with the
the red
red cell
cell as
as its
its
upper left
upper leftcell.
cell.
Sales figures

Jan Feb Mar


North 2300 3200 4500
West 4300 3500 4200
East 5500 6500 6000

Excel 2007 Excel 2010 (Excel 2013 is similar)


Cutting and
Cutting and Pasting
Pasting

Often you
Often you would
wouldlike
like to
to move
move data
data (or
(or shapes,
shapes, such
such as
as text
text boxes)
boxes) from
from one
one
location to another.
location to another.
To move
To move(cut
(cut and
and paste):
paste):

Select the
Select the range
range (or
(or shape)
shape) toto be
be cut,
cut, press
press Ctrl+x
Ctrl+x (for
(for cutting),
cutting), select
selectthe
theupper
upper
left corner
left corner ofof the
thepaste
paste range,
range, and
and press
press Ctrl+v.
Ctrl+v. (The
(Thelittle
little finger/index
finger/index finger
finger
combination on
combination on your
your left
left hand
hand isis also
alsogood
good for
for pressing
pressing Ctrl+x.)
Ctrl+x.)

As with
As with copying
copying and
and pasting,
pasting, ribbon
ribbon buttons
buttons can
can be
be used
usedinstead
instead of
of key
key
combinations, but
combinations, but the
the key
key combinations
combinations are are quicker.
quicker. Also,
Also, note
note that
thatyou
youneed
need
only select
only select the
the upper
upper left
left cell
cellofof the
thepaste
paste range.
range.Excel
Excel knows
knows that
thatthe
the shape
shape of
of
thepaste
the paste range
range must
must bebethe
thesame
sameas as the
theshape
shapeof of the
the cut
cut range.
range.
Tryit!
Try it! Move
Move the
the blue
blue range
rangeto
to the
theright
right so
so that
that itit begins
begins in
in cell
cell in
inthe
the red
red cell.
cell.
(Watch how
(Watch how relative
relativeaddresses
addresses affect
affect the
theeventual
eventual formulas
formulas inin column
column M.)M.)
2 3 6
7 4 28
3 6 18
3 9 27
6 7 42
6 6 36
1 4 4
Other Basic
Other Basic Excel
Excel Tools
Tools

Thetopics
The topicsininthis
this section
sectionhave
have no
no common
commontheme,
theme, and
and they
theyare
arein
in no
no particular
particular
order, but all of them are tools that you should have in your toolkit.
order, but all of them are tools that you should have in your toolkit.
Undoing Mistakes
Undoing Mistakes

Weall
We all make
make mistakes,
mistakes, often
often careless
careless mistakes.
mistakes. For
For example,
example, itit isis easy
easy toto press
press
Ctrl+c (copy) when you mean to press Ctrl+v (paste). This can have
Ctrl+c (copy) when you mean to press Ctrl+v (paste). This can have the effect of the effect of
erasingwhat
erasing what you
you copied
copiedinin aa previous
previous step
step from
from the
the clipboard.
clipboard.At At this
this point,
point, you
you
will be
will be hoping
hopingthat
that you
you can
can easily
easily undo
undo the
themistake.
mistake. This
This isisusually
usually possible,
possible, but
but
not always.
not always. Excel
Excel stores
stores most
most of of your
your actions
actions so
so that
that itit can
can undo
undo them.
them.

There are
There are two
two ways
ways to
to undo
undoactions.
actions.The
Thefirst
firstisisthe
the simplest,
simplest, but
but the
thesecond
second gives
gives
you more
you morecontrol.
control.

To undo
To undo the
the previous
previousaction:
action:

Press Ctrl+z.
Press Ctrl+z.You
You can
can do
do this
thiseasily
easily with
with the
the small
small finger
finger and
and index
index finger
finger of
of your
your
left hand.
left hand. This
This should
should become
becomeoneone of
of your
your favorite
favorite keyboard
keyboard shortcuts!
shortcuts!
Or:
Or:
Click on
Click onthe
the Undo
Undo button
button(the
(the button
button to
tothe
the right
right with
with aacircular
circular arrow
arrow pointing
pointing
counter-clockwise).
counter-clockwise).
This Undo
This Undo button
button isn't
isn't on
onany
anyofof the
theribbons,
ribbons, but
but you
you can
can put put itit on
on the
the Quick
Quick
AccessToolbar
Access Toolbar (QAT)
(QAT) atat the
the top
top of
of the
the screen.
screen. In
Infact,
fact, itit isis typically
typically placed
placed there
there
by default. (There is also a Redo button, also shown to the right,
by default. (There is also a Redo button, also shown to the right, for undoing an for undoing an
undo.)
undo.)
Notethat
Note that there
there isis aa dropdown
dropdown arrowarrow next
next to
to the
the Undo
Undobutton. button.ThisThis allows
allows you
you to
to
select the action (not necessarily the previous action) to undo.
select the action (not necessarily the previous action) to undo. As you can see As you can see
from this
from this dropdown,
dropdown, Excel Excel remembers
remembers aa lot lot of
of your
your most
most recent recentactions.
actions.Just
Just be
be
awarethat
aware thatifif you
youselect
select ,, say,
say, the
the third
third most
most recent
recent action,
action, you you will
will undo
undo this
this
action and
action and the
theother
other twotwo most
most recent
recentactions,
actions, that
that is,
is, itit isis cumulative.
cumulative.

ItItisis hard
hard to
to remember
remember whichwhich actions
actions can
can bebeundone
undoneand andwhich
whichcan't,
can't, but
but you
you can
can
alwaysexperiment.
always experiment. For For example,
example, you
you can't
can't undo
undo adding
addingaa worksheet
worksheet or or deleting
deletingaa
worksheet.This
worksheet. This isis aagood
good reason
reason (one
(oneofof many)
many) for
for saving
saving often!
often!

Tryit!
Try it! Enter
Enter formulas
formulas in
in column
columnM M toto sum
sumthe
the two
two numbers
numbers to
to their
their left.
left. Then
Then get
get
ridof
rid of these
these formulas
formulas with
withCtrl+z
Ctrl+z or
or the
the Undo
Undo button.
button.
25 17
7 21
5 22
16 21
13 33
42 3
37 35
25 43
3 20
32 29
39 22
2 25
23 10
Inserting Rows
Inserting Rows or
or Columns
Columns

Often you
Often you want
wanttoto insert
insert or
or delete
deleterows
rows or
or columns.
columns. Note
Note that
that deleting
deletingaa row
row or
or
column is not the same as clearing the contents of a row or columnmaking
column is not the same as clearing the contents of a row or columnmaking all all
of its
of itscells
cells blank.
blank.Deleting
Deleting aa row
row or
or column
column means
means wiping
wipingitit out
out completely.
completely.

To insert
To insertone
one or
or more
moreblank
blank rows:
rows:

Click aarow
Click row number
number and and drag
drag down
down as as many
manyrows
rows asas you
youwant
want toto insert.
insert. Then
Then
right-click and
right-click and select
select Insert.
Insert. (Alternatively,
(Alternatively, you
youcan
can click
clickthe
the Insert
Insert dropdown
dropdown on on
theHome
the Homeribbon
ribbonandandselect
selectInsert
Insert Sheet
Sheet Rows.
Rows. (Interestingly,
(Interestingly, this
this Insert
Insert
dropdown isis in
dropdown in the
the Cells
Cells group
group of of the
the Home
Home ribbon,
ribbon, not
not on
onthe
the Insert
Insert ribbon.)
ribbon.)

IfIf you
youprefer
preferaa keyboard
keyboardshortcut,
shortcut, press
press Alt+i
Alt+i and
and then
then rr (i(i for
for insert,
insert, rr for
for row).
row).
Therows
The rows you
you insert
insertare
are inserted
inserted above
above the
thefirst
first row
row you
you selected.
selected.For
For example,
example, ifif
you select
you select rows
rows 88through
through 1111 and
and then
theninsert,
insert, four
four blank
blank rows
rows will
will be
beinserted
inserted
between the
between the old
old rows
rows 77 and
and8.8.

Tryit!
Try it! Insert
Insert blank
blank rows
rows for
for the
the data
databelow
below for
for Feb,
Feb, Apr,
Apr, and
and May.
May.

Youcan
You can insert
insert columns
columns in
in exactly
exactly the
the same
same way.
way. The
The keyboard
keyboard shortcut
shortcut Alt+i
Alt+i and
and
then c.c.
then

Month Price Units sold Revenue


Jan $3.00 100 $300.00
Mar $3.25 50 $162.50
Jun $3.50 200 $700.00

Deleting Rows
Deleting Rows or
or Columns
Columns

To delete
To delete one
oneor
or more
more rows:
rows:
Click aarow
Click row number
number andand drag
drag down
down as
as many
manyrows
rows as
as you
youwant
want to
to delete.
delete.Then
Then
right-click and
right-click and select
select Delete.
Delete.(Alternatively,
(Alternatively, you
you can
can click
click the
theDelete
Delete dropdown
dropdown on
on
theCells
the Cells group
group of
of the
theHome
Homeribbon
ribbonand
and select
select Delete
DeleteSheet
SheetRows.
Rows.

IfIf you
youprefer
preferaa keyboard
keyboardshortcut,
shortcut, press
press Alt+e
Alt+e and
andthen
then dd (e
(e for
for edit,
edit, dd for
for delete).
delete).

Tryit!
Try it! Delete
Delete the
therows
rows you
you inserted
inserted in
in the
theabove
aboveexercise.
exercise.

Youcan
You can delete
deletecolumns
columns in
in exactly
exactly the
the same
sameway.
way.The
Thekeyboard
keyboardshortcut
shortcut isis even
even
thesame.
the same.
Youcan
You can delete
deletecolumns
columns in
in exactly
exactly the
the same
sameway.
way.The
Thekeyboard
keyboardshortcut
shortcut isis even
even
thesame.
the same.

Hiding Rows
Hiding Rows or
or Columns
Columns

You can
You can also
alsohide
hide rows
rows or
or columns.
columns. The
The following
followingexplains
explains how
how to
to hide
hideor
or unhide
unhide
rows. The
rows. Thesame
samedirections
directionswork
work for
for columns.
columns.

To hide
To hide aa group
groupof of adjacent
adjacent rows,
rows, click
click the
the top
top row
row number
number youyouwant
want toto hide,
hide,
hold down
hold downthe the Shift
Shift key,
key, and
andclick
click the
the bottom
bottom row
row number
number youyou want
want to
to hide.
hide.This
This
selects the
selects the rows
rows you
you want
want toto hide.
hide. (Alternatively,
(Alternatively, you
youcan
can drag
dragthe
the row
row numbers.)
numbers.)
Then right-click
Then right-click and
andselect
select Hide.
Hide.(Alternatively,
(Alternatively, youyoucan
canclick
click the
theHide
Hideand
andUnhide
Unhide
arrow from the Format dropdown in the Cells group of the
arrow from the Format dropdown in the Cells group of the Home ribbon, as Home ribbon, as
shown to
shown to the
theright.
right. From
From there,
there, click
click on
on Hide
Hide Rows.)
Rows.)

To unhide
To unhide rows,
rows, select
select the
the adjacent
adjacent nonhidden
nonhidden rows.
rows. For
For example,
example, ifif you
you hid
hid rows
rows
65-75, you would select rows 64 and 76. Then right-click and select Unhide
65-75, you would select rows 64 and 76. Then right-click and select Unhide (or (or
usethe
use thedialog
dialogbox
boxto to the
theright).
right).

Try it!
Try it! Hide
Hide any
any subset
subset of
ofthe
therows
rows in
in the
thedata
dataset
set below.
below. Then
Then unhide
unhide them.
them.

Person Age
1 36
2 33
3 49
4 25
5 21
6 46
7 27
8 35
9 22
10 27
11 37
12 36
13 21
14 35
15 39
16 48
17 35
18 38
19 36
20 44
21 34
22 50
23 44
24 41
25 43
26 48
27 29
28 34
29 22
30 28
General Comments
General Comments About
About Worksheets
Worksheets

Worksheets are
Worksheets are where
where youyou place
place your
your data
dataand
and formulas
formulas ininExcel.
Excel.Many
Many people
people
call them "sheets" but this isn't exactly accurate. Strictly speaking, a worksheet isis
call them "sheets" but this isn't exactly accurate. Strictly speaking, a worksheet
aa sheet
sheet that
that has
has rows
rows and
and columns--a
columns--a rectangular
rectangular grid
grid of
of cells.
cells. There
Thereisis another
another
kind of
kind of sheet,
sheet, called
calledaa chart
chart sheet.
sheet. This
Thistype
typeofof sheet
sheet has
hasnono rows
rowsoror columns,
columns,
only aachart.
only chart. The
Thediscussion
discussionherehereisisabout
aboutworksheets,
worksheets, notnotchart
chart sheets.
sheets. The
The
actions discussed below are things you will do every day, so make
actions discussed below are things you will do every day, so make sure you know sure you know
how to
how tododo them
themefficiently.
efficiently.

Renaming aa Worksheet
Renaming Worksheet

Thename
The name of
of aa worksheet
worksheet appears
appears in
in its
its tab
tab at
at the
thebottom
bottomof
of the
the screen.
screen.

To rename
To renameaa worksheet:
worksheet:

Double-click its
Double-click itstab
taband
andtype
typeaa new
new name.
name.

Tryit!
Try it! Rename
Renamethis
this worksheet
worksheetas
as Worksheet
Worksheet Tasks.
Tasks. Then
Then change
change its
its name
name back
back to
to
Manipulating Worksheets.
Manipulating Worksheets.

Adding aa New
Adding New Worksheet
Worksheet

Youoften
You oftenneed
need to
to add
add new
new worksheets.
worksheets.Excel
Excel 2007/2010
2007/2010 makes
makes this
this easier
easier than
than
ever before.
ever before.

To add
To add aanew
new worksheet:
worksheet:

Click the
Click the rightmost
rightmost tab
tab at
atthe
thebottom
bottom of
of the
the screen,
screen, the
thetab
tab to
to the
the right
right of
of your
your
rightmost worksheet tab (see to the right). This creates a new worksheet with aa
rightmost worksheet tab (see to the right). This creates a new worksheet with
generic name
generic name such
suchasas Sheet3,
Sheet3, which
which you
you can
can then
then rename.
rename.

Tryit!
Try it! Create
Createaa new
new worksheet
worksheetand
andrename
rename itit Practice1.
Practice1.

Selecting One
Selecting One or
or More
More Worksheets
Worksheets

Youcan
You can select
select one
oneor or more
more worksheets.
worksheets. The
The "active"
"active" worksheet
worksheet isis the
the one
oneyou
you
areviewing.
are viewing. Its Its tab
tab isis boldfaced.
boldfaced.But
But others
others can
can be
be selected
selected asaswell.
well. IfIfyou
you do
do
anythingto
anything to the
the active
active worksheet,
worksheet, such
such as
as format
formataa cell
cell or
or enter
enter aavalue,
value, the
thesame
same
thingisis done
thing done to to all
all of
of the
the selected
selected worksheets.
worksheets. This
Thiscan
cansave
saveaa lot
lot of
of time
time with
with
common data
common dataor or formatting.
formatting.

To select
To select multiple
multiple adjacent
adjacent worksheets:
worksheets:

Click the tab of the leftmost of these, hold down the Shift key, and click the tab
Selecting One
Selecting One or
or More
More Worksheets
Worksheets

Youcan
You can select
select one
oneor or more
more worksheets.
worksheets. The
The "active"
"active" worksheet
worksheet isis the
the one
oneyou
you
are viewing. Its tab is boldfaced. But others can be selected as well.
are viewing. Its tab is boldfaced. But others can be selected as well. If you do If you do
anythingto
anything to the
the active
active worksheet,
worksheet, such
such as
as format
formataa cell
cell or
or enter
enter aavalue,
value, the
thesame
same
thingisis done
thing done to to all
all of
of the
the selected
selected worksheets.
worksheets. This
Thiscan
cansave
saveaa lot
lot of
of time
time with
with
common data
common dataor or formatting.
formatting.

To select
To select multiple
multiple adjacent
adjacent worksheets:
worksheets:

Click the
Click the tab
tab of
of the
theleftmost
leftmost of
of these,
these, hold
hold down
down the
the Shift
Shift key,
key, and
and click
click the
the tab
tab
of the rightmost of these.
of the rightmost of these.
To select
To select multiple
multiple nonadjacent
nonadjacent worksheets:
worksheets:

Click the
Click the tab
tab of
of any
any of
of them,
them, hold
hold down
downthe
the Ctrl
Ctrlkey,
key, and
and click
clickthe
the other
other tabs.
tabs.

When multiple
When multiple worksheets
worksheetsare areselected,
selected, one
onewill
will be
be active
active (tab
(tab boldfaced),
boldfaced), but
but
thetabs
the tabs of
of the
theothers
others will
will also
also be
bewhite,
white, indicating
indicating that
that they
they are
are selected.
selected. They
They
will remain
will remainselected
selected until
until you
you click
click the
the tab
tab of
ofsome
some other
other worksheet.
worksheet.(There
(Thereisis
oneexception
one exceptiontoto this.
this.IfIf all
all of
of the
the worksheets
worksheets are are selected,
selected, you
you can
can click
click any
any
other worksheet
other worksheet tab
tab to
to activate
activateititand
anddeselect
deselect all
all of
ofthe
the others.)
others.)

Tryit!
Try it! You
You should
should already
alreadyhave
have aa Practice1
Practice1 worksheet.
worksheet. Create
Createseveral
several more
morenewnew
worksheetsto
worksheets to its
its right
rightand
and rename
rename them themPractice2,
Practice2, Practice3,
Practice3, and
andsoso on.
on. Then
Then
select them
select themallall and
andenter
enter the
the label
label "This
"This isis practice"
practice" in
in cell
cell A1
A1 of
of the
the active
active
worksheet, Practice1.
worksheet, Practice1. By By viewing
viewingthe the other
other Practice
Practice worksheets,
worksheets, youyou should
should see
see
that they all have this label in cell A1. Finally, activate the worksheet
that they all have this label in cell A1. Finally, activate the worksheet you are you are
reading now
reading now (Manipulating
(ManipulatingWorksheets).
Worksheets). This Thisdeselects
deselects the
the Practice
Practiceworksheets.
worksheets.

Deleting One
Deleting One or
or More
More Worksheets
Worksheets

Youcan
You can delete
deleteone
one or
or more
more worksheets.
worksheets. However,
However, ifif you
you try
tryto
to delete
delete all
all of
of the
the
worksheets, Excel
worksheets, Excel will
will warn
warnyou
youthat
thatat
at least
least one
one has
hasto to remain.
remain.

To delete
To delete one
oneor
or more
more worksheets:
worksheets:
Select the
Select the ones
ones you
youwant
want to
todelete,
delete, as
asexplained
explained in inthe
the previous
previous text
textbox.
box.Then
Then
right-click any
right-click any of
ofthe
theselected
selectedtabs.
tabs.This
This brings
brings upupaa context-sensitive
context-sensitive menu,
menu,
which has
which hasaa few
few options
options you
you might
might want
want to
to try.
try. For
For now,
now, select
select Delete.
Delete.

Notethat
Note that ifif the
theworksheets
worksheets have
have any
anycontents,
contents, you
you will
will be
be asked
asked ifif you
you really
really
want to
want to delete
deletethem.
them. Deleting
Deleting worksheets
worksheets can
can be
be dangerous
dangerous because
becauseitit cannot
cannot be
be
undone. So
undone. So bebe careful!
careful!

Moving or
Moving or Copying
Copying aa Worksheet
Worksheet

Youcan
You can also
also move
moveoror copy
copy aaworksheet.
worksheet.You
Youcan
can do
do this
this in
inone
one of
of two
two ways:
ways: by
by
dragging tabs or through a Move or Copy menu item. The first way is easier;
dragging tabs or through a Move or Copy menu item. The first way is easier; the the
second gives
second gives you
youmore
more options.
options.

To move
To moveor
or copy
copy aaworksheet
worksheetby
bydragging
dragging its
its tab:
tab:

Dragits
Drag its tab
tab right
rightor
or left
leftto
to the
the position
position you
you want.
want.IfIf you
you hold
holddown
down the
theCtrl
Ctrl key
key
while you
while you are
are dragging,
dragging, you
youwill
will make
make aa copy
copy of
of the
theworksheet.
worksheet.

Tryit!
Try it! Move
Move this
thisworksheet
worksheet to
tothe
the right
rightof
of the
the Fill
Fill aa Series
Series worksheet,
worksheet, and
and then
then
Youcan
You can also
also move
moveor or copy
copy aaworksheet.
worksheet.You
Youcan
can do
do this
this in
inone
one ofof two
two ways:
ways: by
by
dragging tabs
dragging tabs or
or through
through aaMove
Move or
or Copy
Copymenu
menu item.
item. The
The first
first way
wayisis easier;
easier; the
the
second gives you more options.
second gives you more options.
To move
To moveor
or copy
copy aaworksheet
worksheetby
bydragging
dragging its
its tab:
tab:

Dragits
Drag its tab
tab right
rightor
or left
leftto
to the
the position
position you
you want.
want.IfIf you
you hold
holddown
down the
theCtrl
Ctrl key
key
while you
while you are
are dragging,
dragging, you
youwill
will make
make aa copy
copy of
of the
theworksheet.
worksheet.

Tryit!
Try it! Move
Move this
thisworksheet
worksheet to
tothethe right
rightof
of the
the Fill
Fill aa Series
Series worksheet,
worksheet, and
and then
then
move it back again. Next, make a copy of this worksheet, just to the
move it back again. Next, make a copy of this worksheet, just to the right of its right of its
current position.
current position. The
The copy
copy will
will have
have the
the name
name Manipulating
Manipulating Worksheets
Worksheets (2),
(2),
which you
which youcan
can then
thenrename
rename ifif you
youwant.
want. For
For now,
now, delete
delete the
the copy.
copy.

To move
To moveor
or copy
copy aaworksheet
worksheetwith
with the
the Move
Move or
or Copy
Copy menu
menu item:
item:

Right-click the
Right-click theworksheet's
worksheet's tab
taband
and select
selectMove Moveor or Copy.
Copy. This
This brings
brings up
upaa dialog
dialog
that lets
that lets you
you select
select the
theworkbook
workbook you you want
want to to move
move oror copy
copyto to (including
(includingaa new
new
workbook), the position within that workbook, and whether you want to create aa
workbook), the position within that workbook, and whether you want to create
copy. (See
copy. (Seethethescreenshots
screenshots to
to the
the right.)
right.) IfIf you
you select
select aadifferent
different workbook
workbook andand
don't check
don't check the
thelatter
latter option,
option, the
the worksheet
worksheet will will not
not exist
exist in
in the
the current
current file;
file; itit
will move
will move to to the
theother
other workbook.
workbook.So So be
be careful.
careful.
Tryit!
Try it! Create
Createaa new
new worksheet
worksheetcalled
calledPractice
Practice and
and enter
enter some
somedata
data in init.
it.Then
Then
move ititto
move to aanew
new workbook.
workbook.ItIt will
will disappear
disappear from
from this
thisworkbook
workbook and and appear
appear inin aa
new one.
new one. You
You can
can then
then close
closethe
the new
new workbook
workbookandand delete
delete the
the file.
file.

Hidingor
Hiding or Unhiding
Unhiding aa Worksheet
Worksheet

Finally, you
Finally, youcan
can hide
hide oror unhide
unhide aaworksheet.
worksheet.For For example,
example, you
you might
might want
want toto
hide, but
hide, butnot
not delete,
delete, aa worksheet
worksheet that
that contains
contains technical
technical data
data used
used in
in formulas
formulas in
in
other worksheets. Of course, you might be the recipient of such a file,
other worksheets. Of course, you might be the recipient of such a file, with with
formulas you
formulas youcan't
can't figure
figure out
out because
becausethey
they refer
refer to
todata
data on
onaa hidden
hidden worksheet.
worksheet.
IfIf you
yousense
sensethat
that something
something mysterious
mysteriousisis going
goingon,
on, check
check whether
whether there
there are
are any
any
hiddenworksheets!
hidden worksheets!

To hide
To hideaa worksheet:
worksheet:
Right-click the
Right-click theworksheet's
worksheet's tab
taband
and select
selectHide.
Hide.
To unhide
To unhide aaworksheet:
worksheet:

Right-click any
Right-click any worksheet's
worksheet's tab.
tab.IfIf the
the Unhide
Unhideoption
option isis disabled,
disabled, you
you know
know that
that
there are no worksheets to unhide. Otherwise, select Unhide. You will
there are no worksheets to unhide. Otherwise, select Unhide. You will see a listsee a list
of the
of the hidden
hidden worksheets,
worksheets, and
and you
you cancan choose
choose the
the one
oneyou youwant
want to
to unhide.
unhide.

Tryit!
Try it! Hide
Hidethis
this worksheet.
worksheet. Then
Then unhide
unhide it.
it.

Actually, ititisis possible


Actually, possible that
that there
there isis at
at least
least one
one hidden
hidden worksheet
worksheet eveneven ifif the
the
Unhide option
Unhide option isis disabled.
disabled.By By using
using aa macro,
macro, itit isispossible
possible to
to set
setthe
the status
status ofof aa
worksheetto
worksheet to "very
"very hidden."
hidden." Such
Suchworksheets
worksheetscan can bebe unhidden
unhidden only
onlythrough
through
another macro.
another macro.Software
Software companies
companies sometimes
sometimes createcreate very
very hidden
hidden worksheets
worksheets
becausethey
because they know know these
these worksheets
worksheets would would only
only confuse
confuseusers
users (or
(or because
because they they
don't really
don't reallywantwant users
usersto
to see
seetheir
their contents).
contents).
another macro. Software companies sometimes create very hidden worksheets
becausethey
because they know
know these
these worksheets
worksheets would
would only
only confuse
confuseusers
users (or
(or because
because they
they
don't really
don't reallywant
want users
usersto
to see
seetheir
their contents).
contents).
Filling aa Series
Filling Serieswith
with Consecutive
Consecutive Integers
Integers

Suppose you
Suppose you want
wantto
to fill
fill column
column A,
A, starting
startingin
in cell
cell A2,
A2, with
with the
the values
values 1,
1, 2,
2, and
and so
so
on up to 1000. There is an easy way.
on up to 1000. There is an easy way.
To fill
To fill aa column
column range
range with
withaa series:
series:

Enter the
Enter thefirst
first value
value inin the
the first
first cell
cell (1
(1 in
in cell
cell A2).
A2).With
With the thestarting
startingcell
cell (A2)
(A2)
selected, click
selected, click the
theFill
Filldropdown
dropdownin inthe
theEditing
Editinggroup
group of of the
the Home
Home ribbon
ribbon andand
select the
select theSeries
Series option
option toto obtain
obtain aadialog
dialogbox.
box. Fill
Fill itit out
outas as shown
shown below,
below, that
thatis,
is,
select Columns
select Columns (why
(why ononearth
earthisis Rows
Rows the thedefault!?),
default!?), select
selectthetheLinear
Linear Type
Type
option, enter
option, enter 11(the
(the default)
default) in in the
the Step
StepValue
Value box,
box, enter
enter the
the final
final value
value (1000)
(1000) in
in
theStop
the Stop Value
Value box,
box, and
and click
click OK.
OK.

As you
As you can
can guess
guess from
fromthis
this dialog
dialog box,
box, many
manyother
other options
options are
arepossible.
possible. Dont
Dontbe
be
afraid to experiment with them. (See the text box below for more informations
afraid to experiment with them. (See the text box below for more informations
about these
about these options.)
options.)

Tryit!
Try it! The
The series
series of
of days
days in
incolumn
columnKK should
should go
go from
from 11to
to 25,
25, and
and in
incolumn
column N,
N, itit
should go from 26 to 50. Fill these columns.
should go from 26 to 50. Fill these columns.

Other Fill
Other FillOptions
Options

Someof
Some of the
the other
other fill
fill options
options can
can be
be useful.
useful.The
Thefollowing
following explains
explainshow
how aa few
few of
of
them work.
them work.
1.With
1. With the
theLinear
Linear option
option used
used above,
above, each
each successive
successive value
valuechanges
changes by
bythe
the Step
Step
value(which
value (which could
could even
evenbebe negative).
negative).

2.With
2. With the
theGrowth
Growth option
option(short
(short for
for exponential
exponential growth),
growth), the
the ratio
ratio of
of successive
successive
values isis equal
values equal to
to the
the Step
Step value.
value.For
For example,
example, ifif the
the Step
Step value
value isis 1.20,
1.20, each
each
successivevalue
successive value will
will be
be20%
20% above
abovethethe previous
previous value.
value.

3.The
3. TheDate
Date option
optionisis useful
useful ifif you
you want
want aaseries
series of
of date
date to
to be
be separated
separated by
by aagiven
given
Step value.
Step value. In
Inthis
this case,
case, the
theStep
Step value
valueisisdays,
days, weekdays,
weekdays, months,
months, or
or years,
years,
depending on
depending onthe
the Date
Date unit
unitselected
selected on
on the
the right.
right.

4.IfIf you
4. you check
check the
theTrend
Trend option,
option, you
you can
can then
then select
select only
onlyLinear
Linear or
or Growth
Growthas
as the
the
2.With
2. With the
theGrowth
Growth option
option(short
(short for
for exponential
exponential growth),
growth), the
the ratio
ratio of
of successive
successive
values isis equal
values equal to
to the
the Step
Step value.
value.For
For example,
example, ifif the
the Step
Step value
value isis 1.20,
1.20, each
each
successivevalue
successive value will
will be
be20%
20% above
abovethethe previous
previous value.
value.

3.The
3. TheDate
Date option
optionisis useful
useful ifif you
you want
want aaseries
series of
of date
date to
to be
be separated
separated by
by aagiven
given
Step value.
Step value. In
Inthis
this case,
case, the
theStep
Step value
valueisisdays,
days, weekdays,
weekdays, months,
months, or
or years,
years,
depending on
depending onthe
the Date
Date unit
unitselected
selected on
on the
the right.
right.

4.IfIf you
4. you check
check the
theTrend
Trend option,
option, you
you can
can then
then select
select only
onlyLinear
Linear or or Growth
Growthas as the
the
type. Excel
type. Excel then
thencompletes
completes thethebest
bestlinear
linear oror growth
growthpattern
pattern as
as far
far down
downas as you
you
select. For
select. For example,
example, starting
starting with
with the
the four
four values
valuesin incolumn
columnK, K, they
they were
were copied
copied
to darker
to darker blue bluerange
rangeinincolumn
column L,L, the
the entire
entire blue
blue range
range was
was selected,
selected, and and Linear
Linear
Trend was selected. As you can see from the formulas in
Trend was selected. As you can see from the formulas in column M, the best column M, the best
linear fit
linear fit to
tothe
the four
four values,
values, which
which were
werethen
then extended
extended down,
down, increases
increases by by1.05
1.05 inin
each step.
each step.In In aasimilar
similar way,
way, the
the best
best growth
growth fitfit to
to these
thesesame
samefour
four values
values was
was
found in
found in column
column P.P.As
As shown
shownin in column
columnQ, Q, in
in the
thebest
bestgrowth
growthfit,
fit, each
each succeeding
succeeding
value is about 57% larger than the previous value. (Note
value is about 57% larger than the previous value. (Note that if a copy of that if a copy of the
the
original values
original values inincolumn
column KK (or
(or O)
O) had
hadnot not been
been made,
made, thethe original
original values
values would
would
have been
have been overwritten
overwritten by by the
the series.
series. SoSo they
theywould
would have
havebeen
beenlost.)
lost.)
Day Sales Day Sales
$227 $167
$157 $107
$143 $255
$129 $113
$102 $186
$116 $124
$269 $271
$111 $288
$210 $273
$117 $285
$214 $231
$150 $272
$229 $169
$241 $269
$270 $274
$224 $133
$127 $280
$246 $289
$203 $254
$207 $114
$190 $181
$256 $259
$297 $185
$175 $117
$169 $224

Original Series Difference Original Series Ratio


1.1 1 1.1 1.161349
1.9 2.05 1.05 1.9 1.822974 1.569704
3.1 3.1 1.05 3.1 2.861529 1.569704
4.2 4.15 1.05 4.2 4.491754 1.569704
5.2 1.05 7.050725 1.569704
6.25 1.05 11.06755 1.569704
7.3 1.05 17.37278 1.569704
8.35 1.05 27.27013 1.569704
9.4 1.05 42.80603 1.569704
10.45 1.05 67.1928 1.569704
11.5 1.05 105.4728 1.569704
12.55 1.05 165.5611 1.569704
13.6 1.05 259.882 1.569704
14.65 1.05 407.9378 1.569704
15.7 1.05 640.3416 1.569704
16.75 1.05 1005.147 1.569704
Simple Sorting
Simple Sorting with
with A-Z
A-Z or
or Z-A
Z-A

Sorting, which
Sorting, whichusually
usually means
means putting
putting in
in alphabetical
alphabetical order
order or
or increasing
increasing or
or
decreasing numerical order, is a common and simple operation. However,
decreasing numerical order, is a common and simple operation. However, there there
aresome
are some nonobvious
nonobvious things
things you
you should
should know.
know.

Theusual
The usual situation
situation isis that
that you
you have
have aadata
data set
setsuch
such as
as the
theone
one to
to the
the right.
right. IfIfyou
you
want to perform a simple sort on any of its columns, select any single
want to perform a simple sort on any of its columns, select any single data cell in data cell in
this column
this column andand click
click the
the A-Z
A-Z or
or the
the Z-A
Z-A button.
button.You
You can
can find
find these
these buttons
buttons under
under
theSort
the Sort && Filter
Filter dropdown
dropdownon on the
the Home
Home ribbon,
ribbon, and
and they
they are
are also
also on
onthe
the Data
Data
ribbon. But
ribbon. Butbecause
becausetheythey are
are used
used soso often,
often, you
youprobably
probably ought
ought toto add
add them
themto to
the QAT so that they are always accessible.
the QAT so that they are always accessible.
Tryit!
Try it! Sort
Sort on
onany
anyof
of the
the columns
columns to
to the
the right,
right, either
either in
in A-Z
A-Z or
or Z-AZ-A order.
order. Note
Note
that when
that when you
you sort
sort on
on any
any column
column such
such asasSalary,
Salary, the
the other
other columns
columnschangechange
accordingly. That
accordingly. Thatis,
is, each
eachrow
row remains
remains intact.
intact. Of
Of course,
course, this
this isis the
thebehavior
behavior you
you
wouldexpect
would expect and
and want.
want.

Youcan
You can undo
undo aa sort,
sort, but
but just
justinin case,
case, ititisis often
oftennice
nice toto have
have anan "ID"
"ID" column
column with
with
consecutive integers, 1, 2, 3, etc. This is the role of the Person column
consecutive integers, 1, 2, 3, etc. This is the role of the Person column in this data in this data
set. No
set. No matter
matter how
how many
many sorts
sorts you
you do,
do, you youcan
can return
return toto the
the original
original sort
sort order
order
by sorting
by sorting (A-Z)
(A-Z) on
on Person.
Person.

Sorting the
Sorting the Correct
Correct Range
Range

Theabove
The aboveinstructions
instructionssaidsaidto to select
select aa single
single cell
cell before
before you
you click
click A-Z
A-Z oror Z-A.
Z-A. IfIf
you select a range, such as the entire State column, and then click
you select a range, such as the entire State column, and then click A-Z or Z-A, A-Z or Z-A,youyou
will be
will be asked
askedifif you
you want
want to
to expand
expand the
the selection
selection(meaning
(meaningto to the
thefull
full data
dataset)
set) oror
continue with
continue withthe
the current
currentselection.
selection.YouYou probably
probably want
wantthe
the former
former option,
option, not
not
thelatter
the latter one.
one. IfIf you
you continue
continue with
withthe
the current
currentselection,
selection, only
onlythethe Salary
Salaryvalues
values
will be sorted, and the sorted salaries will not correspond to the
will be sorted, and the sorted salaries will not correspond to the right people. right people.

Custom Sorts
Custom Sorts

Excel gives
Excel givesyouyou many
many more
more sort
sort possibilities
possibilities with
with its
itsCustom
Custom Sort Sort item
item under
under the
the
Sort && Filter
Sort Filter items
items(on
(onboth
both the
the Home
Home and and Data
Dataribbons).
ribbons). This
This brings
brings upup aa dialog
dialog
boxwhere,
box where, among
amongother
other things,
things, you
you cancan add
add levels
levels (see
(seetoto the
theright).
right). The
The
example above and to the right illustrates why you might
example above and to the right illustrates why you might want to do this. want to do this.
Suppose you
Suppose you want
wantto
to sort
sort so
so that
that all
all of
of the
themales
males are
are at
at the
thetop.
top.Then
Thenwithin
within each
each
gender, you
gender, youwould
would like
liketo
to sort
sort in
in A-Z
A-Z order
order on
on State.
State.Then
Then ifif there
thereareare multiple
multiple
peopleof
people of aagiven
givengender
gender ininthe
the same
same state,
state, you
you would
would like
like to
to sort
sort them
them inin
decreasing order of Salary. This is possible only with a custom
decreasing order of Salary. This is possible only with a custom sort with three sort with three
levels: first
levels: first Gender,
Gender, then
thenState,
State, then
then Salary.
Salary.

Tryit!
Try it! Sort
Sort the
the data
datastarting
starting in
in row
row 44 as
asexplained
explainedabove.
above.Check
Check that
that itit works
works as
as
intended.
intended.
boxwhere,
box where, amongamongother
other things,
things, youyou cancan add
add levels
levels (see
(seetoto the
theright).
right). The
The
example above
example aboveandandto to the
the right
right illustrates
illustrates why
why you
you might
might want
want to todo
do this.
this.
Suppose you
Suppose you want
wantto
to sort
sort so
so that
that allall of
of the
themales
males are
are at
at the
thetop.
top.Then
Thenwithin
within each
each
gender, you
gender, youwould
would like
liketoto sort
sort in
in A-Z
A-Z order
order on
on State.
State.Then
Then ifif there
thereare
are multiple
multiple
peopleof
people of aagiven
givengender
gender in inthe
the same
same state,
state, you
you would
would like
like to
to sort
sort them
them inin
decreasingorder
decreasing order of
of Salary.
Salary.This
This isis possible
possibleonly
onlywith
withaa custom
customsort sortwith
with three
three
levels: first
levels: first Gender,
Gender, then
thenState,
State, then
then Salary.
Salary.
Tryit!
Try it! Sort
Sort the
the data
datastarting
starting in
in row
row 44 as
asexplained
explainedabove.
above.Check
Check that
that itit works
works as
as
intended.
intended.
Tryititagain!
Try again! This
Thistime
timehave
have the
thethree
three levels
levels be
beSalary,
Salary, then
thenState,
State, then
then Gender.
Gender.DoDo
you see
you see the
the difference?
difference? There
There are
areno
no ties
ties on
onSalary,
Salary, so
so once
onceSalary
Salary isis sorted,
sorted, no
no
moresorting
more sortingtakes
takes place.
place. In
Ingeneral,
general, the
thelower
lower levels
levels apply
apply only
only when
when there
there are
are
ties in the levels above them.
ties in the levels above them.

Sorting Text
Sorting Text

Sorting columns
Sorting columns of
of text
textcan
can bebe tricky,
tricky, especially
especially when
when non-alphabetic
non-alphabetic symbols
symbols are are
present. For
present. For example,
example, sort
sort in
in A-Z
A-Z order
order on
on the
the Grade
Gradecolumn
column to
to the
theright.
right. IsIs this
this
what you
what you expected?
expected? Probably
Probablynot.not.

What about
What about the
theName
Namecolumn
columntoto the
theright,
right, where
wheresome
some names
names are
are upper
upper case
case
andsome
and some are
are lower
lower case?
case? ByBydefault,
default, the
thesort
sort order
order isis case-insentive,
case-insentive, that
that is,
is, case
case
doesn't matter.
doesn't matter. Try
Trysorting
sortingonon Name
Name with
withthe
the A-Z
A-Z button.
button. They
They are
areindeed
indeedsorted
sorted
in alphabetical
in alphabetical order,
order, except
except that
that the
the Name
Name label
labelgot
gotsorted
sortedtoo.
too. (Press
(PressCtrl+z
Ctrl+z toto
undo this sort.) To prevent the label getting sorted, bring up the Custom
undo this sort.) To prevent the label getting sorted, bring up the Custom Sort Sort
dialog box
dialog box and
and check
checkthe
the "My
"Mydata
data has
has headers"
headers" option.
option.

While you
While you are
are inin Custom
Custom Sort
Sortdialog
dialog box,
box, note
note the
the Options
Options button
button at
at the
the top.
top. One
One
option is to check or uncheck the "Case sensitive" box. It is probably
option is to check or uncheck the "Case sensitive" box. It is probably unchecked unchecked
by default.
by default. However,
However, check
check itit and
and then
then sort
sort on
on the
the Name
Name column
column toto the
the right.
right. ItIt isis
still sorted
still sorted inin alphabetical
alphabetical order,
order, ignoring
ignoring case.
case.This
This appears
appears to tobe
be aabug
bugininExcel.
Excel.

Creating aa Custom
Creating Custom List
List for
for Sorting
Sorting

Sometimesyou
Sometimes youwant
want totosort
sortin inaa "natural"
"natural" order,
order, suchsuchas as months
months in in aayear
year (Jan,
(Jan,
Feb, etc.) or days of the week (Sun, Mon, etc.). You can do this
Feb, etc.) or days of the week (Sun, Mon, etc.). You can do this with a custom list.with a custom list.
To get
To gettoto this
this option,
option, bring
bring up
up thethe Custom
Custom Sort
Sort dialog
dialog box, box, click
click the
the Order
Order
dropdown, and
dropdown, and select
selectCustom
Custom List.
List. As
As shown
shown toto the
the right,
right, you
you will
will see
see several
several of
of
custom lists
custom listsbuilt
builtinto
into Excel,
Excel, the
the months
months of of the
the year
year and and the
the days
days ofof the
theweek
week
(either three-letter
(either three-letter abbreviations
abbreviations or or written
written out).
out). YouYou can
canalso
also click
click NEW
NEW LIST
LIST and
and
enter your
enter your own
owncustom
custom list.
list. This
This new
newcustom
custom list
list isis remembered
remembered on on your
your PC
PCfor
for
later uses.
later uses.

Tryit!
Try it! Sort
Sort on
onDay
Day in
in the
thedata
data set
setto
to the
theright,
right, using
using the
thebuilt-in
built-incustom
custom list.
list.Then
Then
create aa new
create new custom
custom listlist with
with items
items Morning,
Morning, Afternoon,
Afternoon, Evening
Evening (in
(in this
this order),
order),
andsort
and sortonon Time
Timeusing
using thisthis custom
custom list.
list.
create aa new
create new custom
custom list
list with
with items
items Morning,
Morning, Afternoon,
Afternoon, Evening
Evening (in
(in this
this order),
order),
andsort
and sortonon Time
Timeusing
using this
this custom
custom list.
list.
Person Age Gender State Children Salary
1 35 Male Ohio 1 $65,400
2 61 Female Illinois 2 $62,000
3 35 Male Illinois 0 $63,200
4 37 Male Indiana 2 $52,000
5 32 Female Ohio 3 $81,400
6 33 Female Illinois 3 $46,300
7 65 Female Illinois 2 $49,600
8 45 Male Ohio 1 $45,900
9 40 Male Illinois 3 $47,700
10 32 Female Ohio 1 $59,900
11 57 Male Illinois 1 $48,100
12 38 Female Indiana 0 $58,100
13 37 Female Indiana 2 $56,000
14 42 Female Ohio 2 $53,400
15 38 Female Ohio 2 $39,000
16 48 Male Ohio 1 $61,500
17 40 Male Indiana 0 $37,700
18 57 Female Indiana 2 $36,700
19 44 Male Illinois 2 $45,200
20 40 Male Ohio 0 $59,000
21 21 Female Indiana 2 $54,300
22 49 Male Ohio 1 $62,100
Grade Name
A+ FRED
A TOM
A- jenny
B+ doug
B MARY
B- sam
C+ charlie
C BOB
C- CHRIS
D+
D
D-
F

Order Time Day


1 Morning Saturday
2 Evening Wednesday
3 Evening Saturday
4 Afternoon Friday
5 Evening Tuesday
6 Morning Tuesday
7 Afternoon Monday
8 Afternoon Saturday
9 Afternoon Monday
10 Morning Tuesday
11 Evening Sunday
12 Morning Monday
13 Afternoon Wednesday
14 Morning Friday
15 Afternoon Saturday
16 Morning Tuesday
17 Afternoon Thursday
18 Afternoon Friday
19 Afternoon Friday
20 Evening Thursday
21 Morning Sunday
22 Morning Monday
23 Morning Sunday
24 Morning Sunday
25 Morning Saturday
Adding Hyperlinks
Adding Hyperlinks

IfIf you
youhave
havenever
never tried
tried using
using hyperlinks
hyperlinks in
inyour
your Excel
Excel files,
files, you
you should
shouldstart
startnow.
now.
They are really easy.
They are really easy.
To create
To create aahyperlink
hyperlink such
such as
as the
theone
one inin cell
cell K3
K3 that
that takes
takes you
you toto the
the Undoing
Undoing
Actions worksheet,
Actions worksheet, right-click
right-clickaa cell
cell and
andselect
selectHyperlink
Hyperlink totobring
bringup up the
the dialog
dialog
box to the right. Enter the label you want in the "Text to display"
box to the right. Enter the label you want in the "Text to display" box. Then, as box. Then, as
you can
you cansee
see inin the
the "Link
"Link to:"
to:" options,
options, youyou can
can choose
chooseseveral
several types
types ofof hyperlinks.
hyperlinks.
Theone
The one illustrated
illustratedhere
hereisisof
of type
type "Place
"Place in in This
This Document",
Document", where
whereyou youcan
can
select aa worksheet
select worksheet and and aacell
cell reference
reference to to link
linkto.
to.

Theother
The other types
types you
you will
will probably
probably use use most
most often
often areare"Existing
"ExistingFile File or
or Web
Web Page"
Page"
and"E-mail
and "E-mail Address".
Address". Actually,
Actually, Excel
Excel isis quite
quitesmart
smart about
about Web
Web sites
sitesand
and email
email
adresses. For
adresses. For example,
example, ifif you
you enter
enter aaURL URL in
in aacell
cell such
such asas
http://www.amazon.com, you won't even
http://www.amazon.com, you won't even need the dialog boxneed the dialog box toto the
the right.
right. Excel
Excel
will immediately
will immediately sense
sensethat
that this
this isis aaURL,
URL, and
and itit will
will add
addthe
the hyperlink
hyperlink
automatically. Then
automatically. Then when
when you
you select
select thisthiscell,
cell, your
your default
default browser
browser willwill open
open and
and
take you
take youtoto the
the specified
specified URL.
URL.Or
Or ifif you
you enter
enter ananaddress
address that
that looks
looks like
like an
an email
email
address, such
address, suchasas jones@aol.com,
jones@aol.com, Excel Excel will
will sense
sense thatthat this
this isis an
an email
email address
addressandand
will add
will add aahyperlink
hyperlink automatically.
automatically. Then Thenwhen
when youyou select
select this
this cell,
cell, your
your default
default
email program
email program will
will start
start up,
up, with
withaa new new message
messageto to this
this address.
address.

Once you
Once you have
have aahyperlink
hyperlink in
in aacell,
cell, you
youcan
canmodify
modify or
or delete
delete itit by
by right-clicking
right-clicking
thecell
the cell and
and choosing
choosing Edit
Edit Hyperlink
Hyperlink or or Remove
Remove Hyperlink.
Hyperlink.

Tryit!
Try it! In
In some
some cell
cell to
to the
theright,
right, create
create aa hyperlink
hyperlink to
to cell
cell A4
A4 of
of the
the Working
Working with
with
Charts worksheet.
Charts worksheet.
Go to Undoing Actions Worksheet
Print Options
Print Options

Printing Excel
Printing Excel worksheets
worksheetsisiseasy
easy---- well,
well, sort
sort of.
of. IfIf you
you want
wantto to print
print aaworksheet,
worksheet,
activate it and press Ctrl+p. This brings up the dialog box to the right,
activate it and press Ctrl+p. This brings up the dialog box to the right, showing showing
theprinter
the printer and
andaa number
number of of settings.
settings. You
You can
can simply
simplyclickclick OK
OK and
and hope
hope for
for the
the
best. However,
best. However, as as you
you have
have probably
probably experienced,
experienced, the theprintout
printoutmight
might not
notbebe
what you
what you want.
want.There
There might
might bebe too
too many
many pieces
pieces of ofpaper
paper printed,
printed, and
andthey
they might
might
be broken into pages in an unappealing
be broken into pages in an unappealing way. way.

Youcan
You can gain
gain aa lot
lot more
more control
control over
over printing
printing by
byclicking
clicking the
the Page
PageSetup
Setuplink
linkat
at the
the
bottom of
bottom of the
the dialog
dialog to
to the
the right
right (from
(from Excel
Excel 2010).
2010). This
This takes
takes you
you to
to the
the Page
Page
Setup dialog
Setup dialog box.
box. The
The Page
Page Setup
Setup dialog
dialog box
box has
has four
four tabs,
tabs, two
two of
of which
which are
are
shown below.
shown below.Here
Here are
are some
some comments/suggestions.
comments/suggestions.

1.The
1. ThePage
Page tab
tab allows
allows youyou to
to choose
choosebetween
between Portrait
Portraitand
andLandscape.
Landscape.In In the
the
Scaling section, you can change the settings to get a better fit to the paper. IfIfyou
Scaling section, you can change the settings to get a better fit to the paper. you
don't have
don't havetootoo much
much on on aaworksheet,
worksheet, you
you can
can select
select the
the "Fit
"Fit to"
to" option
optionandand let
let
everything else
everything else as
as is.
is. Then
Then you
you are
are assured
assured that
that the
the selected
selected Print
Print area
area (see
(seenext
next
point) will
point) will be
be printed
printed on onaa single
single piece
piece of
of paper.
paper.

2.The
2. TheSheet
Sheettab
tablets
lets you
youspecify
specifythe
the Print
Printarea
areayou
youwant
want printed.
printed. You
You can
canalso
also
specify whether
specify whether you
youwant
want gridlines
gridlines and/or
and/or row
row and
and column
column headings
headings to
to show.
show.

So experiment
So experimentwith
with these
these (and
(andmany
manyother
other )) print
print options.
options. You
You do
do have
haveaa lot
lot of
of
control over
control over what
what isis printed
printed and
and how
how itit looks
looks on
on the
the paper.
paper.

Youmight
You mightsometimes
sometimes find
find that
that certain
certainobjects
objects like
like text
text boxes,
boxes, buttons,
buttons, and
and
arrows do not get printed. To remedy this, right-click on the object, select
arrows do not get printed. To remedy this, right-click on the object, select Size Size
andProperties,
and Properties, and
and click
clickthe
theProperties
Properties tab.
tab.This
This contains
contains aa"Print
"Printobject"
object" option
option
that you
that you can
can check
checkor or uncheck.
uncheck.
Introduction to
Introduction to Excel
Excel Formulas
Formulas

Among other
Among other things,
things, Excel
Excel isis aareally
reallyefficient
efficient calculator.
calculator.ToTo use
useitit in
in this
this role,
role, you
you
have to enter formulas in cells. If at all possible, you should try to
have to enter formulas in cells. If at all possible, you should try to structure your structure your
worksheetsso
worksheets so that
that formulas
formulas are are copyable.
copyable.TheThe next
next few
few sheets
sheetsprovide
provide some some
basics about
basics about formulas,
formulas, including
including the the crucial
crucial concept
concept ofof relative
relativeand
andabsolute
absolute
addresses for
addresses for copying.
copying. To To do
do anything
anythingof of much
much interest
interest in
in Excel,
Excel, you
you absolutely
absolutely
have to master this concept.
have to master this concept.
Reasons for
Reasons for Relative/Absolute
Relative/Absolute Addressing
Addressing

Absoluteand
Absolute and references
references are
areindicated
indicated ininformulas
formulasby bydollar
dollar signs
signs (absolute)
(absolute) or or
the lack of (relative), and they indicate what happens when you copy or move aa
the lack of (relative), and they indicate what happens when you copy or move
formulato
formula to aarange.
range. You
You typically
typically want
wantsome
some parts
parts of
of the
the formula
formula to to stay
stay fixed
fixed
(absolute) and
(absolute) and others
others to
tochange
change relative
relativeto
to the
thecell
cell position.
position. This
This isis aa crucial
crucial
concept in
concept in spreadsheet
spreadsheet operations,
operations, soso you
youshould
should take
take some
some time
time to to understand
understand
it thoroughly. Here are two important things to
it thoroughly. Here are two important things to remember: remember:

(1) The
(1) Thedollar
dollar signs
signs are
arerelevant
relevant only
only for
for the
thepurpose
purpose of
of copying
copyingoror moving;
moving; they
they
have no
have no inherent
inherenteffect
effecton on the
theformula.
formula.For For example,
example, the
the formulas
formulas =5*B3
=5*B3and and
=5*$B$3in
=5*$B$3 incell
cell C3,C3, say,
say, produce
produceexactly
exactly the
the same
sameresult.
result.Their
Their difference
difference isis
relevantonly
relevant only ifif you
you want
want to
to copy
copycell
cell C3
C3 to
to some
some range.
range.

(2) There
(2) There isis never
never any
any need
need to
to type
type the
thedollar
dollar signs.
signs. You
You can
can do
doititwith
with the
the F4
F4key.
key.
This isis an
This an extremely
extremely important
important concept
conceptin inExcel.
Excel.There
There isis no
nobetter
better way
way to
to be
be
efficient (and
efficient (and avoid
avoiderrors)
errors) than
than to
to set
set up
up aaspreadsheet
spreadsheet for for copying.
copying. This
This often
often
requires some
requires some careful
careful planning,
planning, but
but the
the time
time spent
spent inin planning
planning isis more
more than
than
made up for by efficient copying. So always be on the lookout
made up for by efficient copying. So always be on the lookout for ways to for ways to make
make
copyingpossible,
copying possible, and
and then
then take
take advantage
advantageof of relative/absolute
relative/absoluteaddressing
addressing inin your
your
formulas to
formulas to get
getthe
the correct
correctresults.
results.

Creating Relative/Absolute
Creating Relative/Absolute Addresses
Addresses

To make
To makeaa cell
cell reference
reference absolute
absolute or
or mixed
mixed absolute/relative
absolute/relative using
using the
the F4
F4 key:
key:
Enter aa cell
Enter cell reference
reference such
such as
as =B3
=B3 in
in aaformula.
formula. Then
Thenpress
press the
the F4
F4key.
key.

In fact,
In fact, ifif you
you press
press thetheF4F4 key
key repeatedly,
repeatedly, you
you cycle
cycle through
throughthe
the possibilities:
possibilities: B3B3
(neither row
(neither row nor
nor column
column fixed),
fixed), then
then $B$3
$B$3 (both
(bothcolumn
column BBand
androw
row 33 fixed),
fixed), then
then
B$3(only
B$3 (onlyrow row 33 fixed),
fixed), then
then $B3
$B3 (only
(only column
column BB fixed),
fixed), and
and back
back again
again toto B3.
B3.

Tryit!
Try it! Enter
Enter the
theappropriate
appropriateformula
formula inin the
the darker
darker blue
blue cell
cell to
tothe
the right,
right, and
and then
then
copyacross
copy across to
to the
the other
other blue
blue cells.
cells.(Scroll
(Scroll to
to the
theright
right to
to see
seethetheanswer.)
answer.)

Tryititagain!
Try again! Enter
Enter one
oneformula
formulawithwith appropriate
appropriate absolute/relative
absolute/relative addressing
addressing in in
thedarker
the darker red
red cell
cell to
to the
the right,
right, and
and then
then copy
copy itit to
to entire
entire red
red range.
range. (Scroll
(Scroll to
tothe
the
right to
right tosee
see the
theanswer.)
answer.)
Fixed cost $50
Variable cost $2

Month Jan Feb Mar Apr


Units produced 224 194 228 258
Total cost

Table of revenues for various unit prices and units sold

Units sold
50 100 150 200
Unit price $3.25
$3.50
$3.75
$4.00
$4.25
Fixed cost $50
Variable cost $2

Month Jan Feb Mar


Units produced 224 194 228
Total cost $498 $438 $506

Units sold
50 100
Unit price $3.25 $162.50 $325.00
$3.50 $175.00 $350.00
$3.75 $187.50 $375.00
$4.00 $200.00 $400.00
$4.25 $212.50 $425.00
Apr
258
$566

150 200
$487.50 $650.00
$525.00 $700.00
$562.50 $750.00
$600.00 $800.00
$637.50 $850.00
The Meaning
The Meaning of
of R1C1
R1C1Notation
Notation

Speaking of
Speaking of relative
relative and
and absolute
absolute addresses
addresses in
in formulas,
formulas, itit isis pretty
pretty amazing
amazinghowhow
intelligent spreadsheets are. When you copy a formula in cell C1
intelligent spreadsheets are. When you copy a formula in cell C1 such as =A1+B1 such as =A1+B1
down, ititautomatically
down, automatically changes
changes appropriately:
appropriately: =A2+B2,
=A2+B2, then
then =A3+B3,
=A3+B3, and
and so
so on.
on.
In aasense,
In sense, these
these are
are all
all the
the same
same formula.
formula. Each
Each says
says to
to add
addthe the two
two values
values to
to the
the
left of
left of the
thecurrent
current cell.
cell.

Excel allows
Excel allows youyou to
to see
see this
this equivalence
equivalence even even more
more clearly
clearlybybyviewing
viewing the
the
formulas in
formulas in aadifferent
different format,
format, called
called R1C1
R1C1 notation.
notation. InIn this
this format,
format, each
each of
of the
the
formulas in
formulas in column
column CC isis written
written as as=RC[-2]+RC[-1].
=RC[-2]+RC[-1].RR stands
stands forfor row,
row, and
andCC stands
stands
for column.
for column. TheThefact
fact that
that there
there isisnothing
nothing next
next to
to RRmeans
meansthatthatyou youstay
stay in
in the
the
same row.
same row. The
The numbers
numbers in in brackets
brackets next
next totoCC mean
mean totogogo 22 columns
columns to tothe
the left
left
and11 column
and column to to the
the left,
left, respectively.
respectively.(For
(For columns,
columns, negative
negative numbers
numbers mean
mean to to
go to
go tothe
the left,
left, positive
positiveto to the
the right.
right. For
For rows,
rows, negative
negative numbers
numbers mean mean to
to go
goup,up,
positive down.)
positive down.)

IfIf there
thereisis aa number
number next
nextto
to RR or
or CCthat
thatisis not
not in
in brackets,
brackets, ititindicates
indicates an
anabsolute
absolute
reference.For
reference. For example,
example, =R2C[2]
=R2C[2] placed
placed inin cell
cell D5
D5 isis equivalent
equivalent toto =F$2
=F$2 because
because
therow
the row reference
reference isis absolute
absolute and
and the
thecolumn
columnreference
reference isis relative
relative to
tocolumn
column D.
D.

Showing Formulas
Showing Formulas in
in R1C1
R1C1Notation
Notation

Theusual
The usual way
wayof
of expressing
expressing formulas,
formulas, such
such as
as=C5+D5,
=C5+D5, isis called
called A1
A1format.
format. The
The
way discussed here is called R1C1 format. You can easily toggle between them.
way discussed here is called R1C1 format. You can easily toggle between them.
To toggle
To toggle between
betweenA1
A1 and
and R1C1
R1C1formats:
formats:

Openthe
Open theExcel
Excel Options
Options dialog
dialogbox,
box, select
select Formulas,
Formulas, and
andcheck
check or
or uncheck
uncheck the
the
R1C1 reference
R1C1 reference style
style option
option (see
(see to
to the
theright,
right, from
fromExcel
Excel 2010).
2010).

Tryit!
Try it! Toggle
Togglebetween
between A1
A1 and
and R1C1
R1C1 reference
reference style
style and
and for
for either,
either, examine
examine the
the
formulas inside the border and in the Total row above.
formulas inside the border and in the Total row above.
Note: One
Note: One Excel
Excel book
book author
author suggested
suggested that
that we
we should
should move
move exclusively
exclusively to
toR1C1
R1C1
notation, arguing
notation, arguing that
that itit makes
makesmore
more logical
logical sense.
sense. He
He might
mightbe
be right
right about
about the
the
logic, but
logic, butthis
this isisnever
never going
goingto to happen.
happen.WayWaytootoo many
many people
people are
are way
way too
tooused
used
to the
to the A1
A1notation,
notation, andand theythey are
are not
notabout
abouttoto change!
change!
Multiplication table
1 2 3 4
1 1 2 3 4
2 2 4 6 8
3 3 6 9 12
4 4 8 12 16
Total 10 20 30 40
Basics of
Basics of Named
Named Ranges
Ranges

Range names
Range names areare used
used forfor one
one basic
basic purpose:
purpose: to
to mak
mak your
your formulas
formulas more
more
readable. After all, which formula makes more sense: =B20-B21
readable. After all, which formula makes more sense: =B20-B21 or =Revenue-or =Revenue-
Cost? Efficient
Cost? Efficientuse
use ofof range
range names
names takes
takes some
someexperience,
experience, but
but this
this sheet
sheet
provides aa few
provides few useful
useful tips.
tips.

AA range
range name
name cancanbe be applied
applied to to aasingle
single cell
cell or
or to
to any
any range
rangeof of cells.
cells. There
There are
areaa
few rules
few rules for
for the
thenames
names youyoucancanuse.
use.The
Themost
most important
importantareare that
that(1)(1) the
the names
names
cannot include
cannot include aafewfew "illegal"
"illegal" characters,
characters, the
themost
most common
common beingbeing spaces,
spaces, and
and (2)
(2)
they can't
they can'tlook
look like
like cell
cell addresses.
addresses. ForFor example,
example, DAN37
DAN37isisillegal
illegal because
becauseDAN37
DAN37
isis aa cell
cell address
address (at
(at least
least in
in Excel
Excel 2007
2007 and
and more
more recent
recentversions).
versions).

Youcan
You can definitely
definitely go
go overboard
overboard in in the
the use
use of
of named
named ranges,
ranges, and
and you
you can
can err
err in
in
theother
the other direction
direction by
by refusing
refusing to
to use
use them.
them.YouYoushould
should use
usesome
some discretion
discretion(and
(and
possibly company
possibly companypolicy)
policy) when
when deciding
deciding how
how much
muchto
to use
usenamed
named ranges.
ranges.

Range names
Range names have
havebeen
beenavailable
available for
for many
manyyears,
years, but
but they
theyare
are more
moreprominent
prominent
in Excel
in Excel 2007
2007and
andmoremorerecent
recent versions.
versions.Their
Their functionality
functionalityisisin
inthe
theDefined
Defined
Names group,
Names group, right
right in
in the
the middle
middle of
of the
the Formula
Formularibbon
ribbon (see
(see to
tothe
the right).
right).

Naming aa Range
Naming Range in
in the
the Name
Name Box
Box

Theeasiest
The easiest and
and best-known
best-knownway way to
to name
nameaa range
range isis to
touse
use the
the Name
Name box,
box, just
justto
to
theleft
the left of
of the
the Formula
Formulabar
bar (see
(see to
to the
theright,
right, where
wherethe the Name
Name box
box originally
originally
contains aacell
contains cell address
address).).
To create
To create aarange
range name
name with
withthe
the Name
Name box:
box:

Select aarange
Select range you
you want
want to
toname
name (which
(whichcould
could be
be aa single
singlecell),
cell), click
click in
in the
theName
Name
box, type
box, type aarange
range name,
name, and
and press
press Enter.
Enter. Don't
Don't forget
forgetto
to press
pressEnter
Enter after
after typing
typing
therange
the rangename;
name; otherwise,
otherwise, the
the name
name you
you type
type won't
won't"stick."
"stick."

Tryit!
Try it! Name
Name the
theblue
blue range
range to
tothe
the right
rightData.
Data.

TheName
The Nameboxboxisis also
also useful
useful for
for finding
finding named
namedranges.
ranges. ToTo do
do so,
so, click
click the
the
dropdown arrow
dropdown arrow in inthe
the Name
Name boxbox toto see
see aalist
listof
of all
all range
range names,
names, and
and click
click one
one of
of
them. This
them. This will
will select
select the
the corresponding
corresponding range.
range.

Using the
Using the Name
Name Manager
Manager

Youget
You get much
muchmoremore control
control ofof named
named ranges
ranges bybyclicking
clicking the
the Name
Name Manager
Manager on on
theFormulas
the Formulas ribbon.
ribbon. This
This displays
displays the
the dialog
dialog box
box to
to the
the right.
right. ItItshows
shows aa list
list of
of all
all
range names in your workbook, the values in these
range names in your workbook, the values in these ranges, and theranges, and the
corresponding range
corresponding range addresses.
addresses. YouYou can
can select
select any
any range
range name
name and and then
then Edit
Edit oror
Delete it.
Delete it. You
You can
can also
also click
click the
the New
New button
button toto create
create aa new
new named
named range.
range. InIn this
this
case, you
case, you need
need toto supply
supplyaa name
name and
and an
anaddress.
address.
Using the
Using the Name
Name Manager
Manager

Youget
You get much
muchmoremore control
control ofof named
named ranges
ranges bybyclicking
clicking the
the Name
Name Manager
Manager on on
theFormulas
the Formulas ribbon.
ribbon. This
This displays
displays the
the dialog
dialog box
box toto the
the right.
right. ItItshows
shows aa list
list of
of all
all
range names
range names in in your
your workbook,
workbook, the the values
values in
in these
these ranges,
ranges, and
andthe the
corresponding range
corresponding range addresses.
addresses. YouYou can
can select
select any
any range
range name
name and and then
then Edit
Edit oror
Delete it.
Delete it. You
You can
can also
also click
click the
the New
New button
button toto create
create aa new
new named
named range.
range. InIn this
this
case, you
case, you need
need toto supply
supplyaa name
name and
and an
anaddress.
address.

Tryit!
Try it! Rename
Renamethethe above
above blue
bluerange
rangeas
as MyData.
MyData. Then
Thendelete
deletethe
the MyData
MyData range
range
name. Then
name. Then use
use the
theName
NameManager
Manager to
to create
create the
theData
Datarange
rangename
name again.
again.

Using the
Using the Create
Create from
from Selection
Selection Shortcut
Shortcut

Suppose you
Suppose you have
have the
the labels
labelssuch
such asas Revenue,
Revenue, Cost,
Cost, and
and Profit
Profit in
in some
somerange,
range, and
and
you would
you would like
like the
theadjacent
adjacent cells
cells (which
(whichwill
will contain
contain the
thevalues
valuesof of revenue,
revenue, cost,
cost,
andprofit)
and profit) to
to have
havethese
theserange
rangenames.
names. There
There isis aavery
very quick
quick way
way to to do
do this.
this.

To create
To create range
range names
namesfrom
fromadjacent
adjacentlabels:
labels:

Select the
Select the range
range consisting
consisting of
of the
the labels
labels and
and the
thecells
cells to
to be
be named.
named.ThenThen click
click the
the
Create from
Create from Selection
Selection button
buttonin in the
the Defined
DefinedNames
Names group
group on on the
the Formulas
Formulas
ribbon. In
ribbon. In the
the resulting
resulting dialog
dialogbox,
box, make
makesure
sure the
the appropriate
appropriate option
option(in
(in this
this case,
case,
Left Column)
Left Column) isis checked,
checked, and
andclick
click on
onOK.
OK.
Excel tries,
Excel tries, usually
usuallysuccessfully,
successfully, to
to guess
guesswhere
wherethe
thelabels
labels are
are that
that you
you want
wantto
to
useas
use as range
range names
names (see
(see to
to the
theright).
right). You
You can
canalways
always override
override its
its guess.
guess.
(Uncheck Left
(Uncheck Left column.)
column.)

Tryit!
Try it! Name
Name each
each of
of the
thecolored
colored ranges
rangesto
to the
theright
right according
according to
to the
the labels
labels in
inthe
the
row above
row above them.
them.

Applying New
Applying New Range
Range Names
Names to
to Existing
Existing Formulas
Formulas

IfIf you
youcreate
createrange
rangenames
names and
and then
thencreate
create formulas
formulas that
that reference
reference these
these ranges,
ranges,
Excel uses
Excel uses the
the range
range names
names automatically.
automatically. Sometimes,
Sometimes, however,
however, youyou do
do itit in
inthe
the
opposite order. That is, you enter a formula using cell addresses, such
opposite order. That is, you enter a formula using cell addresses, such as =B20- as =B20-
B21, and
B21, and later
later you
youname
name B20
B20as
as Revenue
Revenueand and B21
B21 as
as Cost.
Cost. The
The formula
formula does
does not not
changeto
change to =Revenue-Cost
=Revenue-Cost automatically.
automatically. However,
However, you
youcan
can make
make ititchange
change (and (and
hence become
hence become moremorereadable)
readable) as
as follows.
follows.

To apply
To apply range
range names
names to
toan
an existing
existing formula:
formula:

Select the
Select the formula
formula cell,
cell, and
and select
select Apply
ApplyNames
Names fromfrom the
the Define
Define Name
Name
dropdown in the Defined Names group (see to the right). Then
dropdown in the Defined Names group (see to the right). Then select all select all range
range
names that
names that apply
applyto
to this
thisformula.
formula.(Actually,
(Actually, you
you can
can select
select several
several formulas
formulas and
and
applyrange
apply rangenames
names to
to all
all of
of them
thematat once.)
once.)

Tryit!
Try it! You
You should
should now
now have
havethe
therange
rangenames
names UnitsSold
UnitsSoldand
andRevenue
Revenue forfor the
the red
red
andorange
and orangeranges
ranges above.
above.Apply
Applythese
theseto
to the
the SUM
SUM formulas
formulas in
in the
theTotals
Totals row.
row.
names that apply to this formula. (Actually, you can select several formulas and
applyrange
apply rangenames
names to
to all
all of
of them
themat
at once.)
once.)

Tryit!
Try it! You
You should
should now
now have
havethe
therange
rangenames
names UnitsSold
UnitsSoldand
andRevenue
Revenue for
for the
the red
red
and orange ranges above. Apply these to the SUM formulas in the Totals
and orange ranges above. Apply these to the SUM formulas in the Totals row.row.

Pasting aa List
Pasting List of
of Range
Range Names
Names for
for Documentation
Documentation

IfIf you
youhave
havemany
many range
range names,
names, ititisis often
oftenuseful
useful to
to show
show aalist
list of
of them
them and
and the
the
range addresses
range addresses they
they apply
apply to.
to.

To paste
To paste aa list
listof
of all
all range
range names
names on
on aa worksheet:
worksheet:

Select aacell
Select cell with
with plenty
plenty of
of blank
blank space
spacebelow
below it,
it, select
select the
the Use
Use in
in Formula
Formula
dropdown in
dropdown in the
theDefined
Defined Names
Names group,
group, and
and click
click on
onthe
the Paste
Paste Names
Names option
option (see
(see
to the right).
to the right).
Tryit!
Try it! Paste
Pasteaa list
list of
of all
all range
range names,
names, starting
starting in
in the
thered
redcell
cell to
to the
the right.
right.Note
Notethat
that
you will
you will see
see aalist
listof
of all
all range
range names
names in
inthis
this workbook,
workbook, including
includingthose
those on
onother
other
worksheets.
worksheets.
71 31 9 69 5
15 74 46 84 27
14 49 25 38 83
40 43 20 75 83
28 72 30 92 75
41 56 90 89 73
28 81 43 81 61
Month UnitsSold UnitPrice Revenue
Jan 100 $1.25 $125.00
Feb 150 $1.25 $187.50
Mar 200 $1.40 $280.00
Apr 230 $1.40 $322.00
May 200 $1.50 $300.00
Jun 300 $1.50 $450.00
Totals 1180 $1,664.50
Range names used in this workbook:
Using the
Using the Formula
Formula Auditing
AuditingButtons
Buttons to
to Trace
Trace Precedents
Precedents and
and Dependents
Dependents

There are
There are times
times when
whenyou youwill
will receive
receive aaspreadsheet
spreadsheet fromfrom aacolleague
colleague andand you
you
will have absolutely no idea how its various cells are related. Where
will have absolutely no idea how its various cells are related. Where are the are the
constants? Where
constants? Where are
are the
the formulas?
formulas? How How dodo the
theformulas
formulas incorporate
incorporate thethe
constants? How
constants? How do
do the
theformulas
formulas build
build upon
upononeone another?
another? In Inthese
thesevery
very common
common
situations, Excel's
situations, Excel's auditing
auditing tools
toolscan
can be
be aahuge
hugehelp.
help. They
They let
let you
you find
find the
the
precedents and
precedents and dependents
dependents of of any
any particular
particular cell,
cell, defined
defined asasfollows.
follows.

1.The
1. The precedents
precedents of
of any
any cell
cell that
thatcontains
contains aa formula
formulaare
areall
all cells
cells referenced
referencedby
by
theformula
the formulain
inthat
thatcell.
cell. (If
(If aa cell
cell doesn't
doesn't contain
contain aaformula,
formula, itit can't
can't have
haveany
any
precedents.)
precedents.)
2.The
2. The dependents
dependents of
of any
any cell
cell are
are all
all cells
cellswith
with formulas
formulas that
that reference
referencethat
thatcell.
cell.
TheFormula
The Formula Auditing
Auditinggroup
group on
on the
the Formulas
Formulas ribbon
ribbon hashas buttons
buttons for for tracing
tracing
precedents and
precedents and dependents
dependents (see
(see the
the screenshot
screenshot to to the
the right).
right). IfIf you
you select
select aacellcell
andclick
and click Trace
Trace Precedents,
Precedents, you
youwill
will see
see arrows
arrowsfromfrom all
all of
of the
the cell's
cell's precedents
precedents to to
it. IfIf you
it. you click
clickTrace
Trace Dependents,
Dependents, you
youwill
will see
see arrows
arrows fromfrom thethe cell
cell to
to all
all of
of its
its
dependents. (Click
dependents. (Click the
the Remove
Remove Arrows
Arrows button
buttonto to get
get rid
rid of
of these
these arrows.)
arrows.)

Youcan
You can do
do this
thismultiple
multipletimes.
times. For
For example,
example, ifif you
you show
show aacell's
cell's dependents
dependents and
and
thenclick
then click again
againTrace
Trace Dependents,
Dependents, youyouwill
will see
see all
all of
of the
thedependents'
dependents'
dependents.
dependents.
Tryit!
Try it! In
In the
the example
example toto the
theright,
right, aacompany
companysends
sends catalogs
catalogs to
to customers,
customers, which
which
costs money.
costs money. Unfortunately,
Unfortunately, only
only aasmall
small percentage
percentage ofof these
these customers
customers responds
responds
by purchasing
by purchasing something.
something. UseUsethe
the formula
formulaauditing
auditing buttons
buttons totolearn
learn what
what isis
relatedto
related to what.
what. This
This should
should help
help you
youunderstand
understandthe
thebusiness
business model
model and
and how
how itit
hasbeen
has beenimplemented
implemented in in Excel.
Excel.

Note: Many
Note: Many spreadsheets
spreadsheets in in real
real businesses
businesseshavehavecells
cells that
that aren't
aren't related
relatedto to
anything. That
anything. Thatis,
is, they
theyhave
havenono precendents
precendents or or dependents.
dependents.Typically,
Typically, this
this isis not
not
good.ItIt could
good. could mean
meanthat that the
theconstants
constants in
in these
these cells
cellsare
are "hard-coded"
"hard-coded" (entered
(entered
as constants)
as constants) ininone
one oror more
moreformulas,
formulas, which
which isis always
always aa bad
bad practice.
practice. ItItcould
could
also mean that these constants have been incorporated
also mean that these constants have been incorporated in the model with in the model with
"mental arithmetic"
"mental arithmetic" rather
rather than
thanformulas,
formulas, another
another badbad practice.
practice. See
See ifif you
you cancan
find examples
find examples of of such
such "dangling"
"dangling" constants
constants inin the
theexample
exampleto to the
the right.
right.Then
Then
incorporate them
incorporate them withwithappropriate
appropriate formulas.
formulas.

Showing Formulas
Showing Formulas

AA common
common wish
wish isis to
to see
seeall
all of
of the
the formulas,
formulas, not
not their
their values.
values. This
This isis easy.
easy. Just
Just
clickthe
click the Show
Show Formulas
Formulas button
button inin the
the Formula
Formula Auditing
Auditing group.
group. This
This button
button isis
actually aatoggle
actually togglebetween
between values
valuesand
andformulas.
formulas.(Equivalently,
(Equivalently, you
youcan
can useuse
keyboardshortcut
keyboard shortcut Ctrl-~.)
Ctrl-~.)

Tryit!
Try it! Click
Clickthe
the Show
Show Formulas
Formulas button
button to
to see
see all
all formulas
formulas in
in the
the above
abovemodel.
model.
Then click
Then click this
this button
button again
again to
to show
show the
the values.
values. Note
Note that
that the
thecolumns
columns expand
expand
when you
when youshow
show formulas,
formulas, but
but fortunately
fortunately they
they revert
revertback
back toto their
their original
original widths
widths
when you show values.
Showing Formulas
Showing Formulas

AA common
common wish
wish isis to
to see
seeall
all of
of the
the formulas,
formulas, not
not their
their values.
values. This
This isis easy.
easy. Just
Just
click the Show Formulas button in the Formula Auditing group. This button isis
click the Show Formulas button in the Formula Auditing group. This button
actually aatoggle
actually togglebetween
between values
valuesand
andformulas.
formulas.(Equivalently,
(Equivalently, you
youcan
can useuse
keyboardshortcut
keyboard shortcut Ctrl-~.)
Ctrl-~.)

Tryit!
Try it! Click
Clickthe
the Show
Show Formulas
Formulas button
button to
to see
see all
all formulas
formulas in
in the
the above
abovemodel.
model.
Then click
Then click this
this button
button again
again to
to show
show the
the values.
values. Note
Note that
that the
thecolumns
columns expand
expand
when you
when youshow
show formulas,
formulas, but
but fortunately
fortunately they
they revert
revertback
back toto their
their original
original widths
widths
when you
when youshow
show values.
values.
Unit printing cost $0.10
Unit mailing cost $0.15
Variable cost of printing and mailing $0.25
Number mailed 100000

Average revenue per order $60


Order fulfillment cost (% of revenue) 60%
Variable cost per order fulfillment $36.00

Response rate 3%
Number of responses 3000

Total Revenue $180,000


Fixed cost of printing $20,000
Total variable cost of printing and mailing $25,000
Total variable cost of order fulfillment $108,000
Total cost $153,000
Profit $27,000
CalculationOptions
Calculation Options

Youmight
You mightnot
not even
even think
think about
about it,
it, but
butExcel
Excel isis an
an amazing
amazingcalculation
calculation engine.
engine. Not
Not
only does it calculate a formula as soon as you enter it, but it
only does it calculate a formula as soon as you enter it, but it recalculates recalculates
everything that
everything that isis affected
affected by by any
anychanges
changes you
you makemakeininany
anycell
cell or
or range
range ofofany
any
worksheet.This
worksheet. This behavior
behavior isis called
called Automatic
Automatic recalculation,
recalculation, and
and itit isis the
thebehavior
behavior
you are
you areaccustomed
accustomed to to in
in Excel.
Excel.

However, there
However, thereare
aretwo
twoother
other calculation
calculation "modes"
"modes" in
in Excel:
Excel: Automatic
Automatic Except
Except for
for
Data Tables
Data Tables and
and Manual.
Manual.

To change
To change the
the calculation
calculation setting:
setting:

Click the
Click the Calculation
Calculation Options
Options dropdown
dropdown listlistfrom
fromthe
theFormulas
Formulas ribbon
ribbonand
andselect
select
any of
any of the
the three
three options
options (see
(see to
to the
theright).
right).
With the
With the Automatic
Automatic Except
Exceptfor
for Data
DataTables
Tables setting,
setting, aadata
datatable
table (see
(see the
the Data
Data
Tablesheets
Table sheets in
in this
thistutorial)
tutorial) will
will not
notrecalculate
recalculate until
until you
you force
force ititto
to (see
(see the
the text
text
boxbelow).
box below).This
This isis useful
useful because
because data
data tables
tables can
can take
take aa long
long time
time to to recalculate.
recalculate.

With the
With the Manual
Manual setting,
setting, nothing
nothing recalculates
recalculatesuntil
until you
youforce
forceaa recalculation.
recalculation. This
This
mightbe
might be useful
useful when
when your
your workbook
workbook hashas many
many complex
complex formulas
formulas and and you
youdon't
don't
want them
want them toto recalculate
recalculate until
until you
you force
force them
them to.
to.However,
However, ifif you
you somehow
somehow turn
turn
this setting on by accident, the resulting Excel behavior will not be what
this setting on by accident, the resulting Excel behavior will not be what you are you are
usedto!
used to!

Forcing aa Recalculation
Forcing Recalculation

Theeasiest
The easiest and and most
mostcommon
commonway way to
to force
force aarecalculation
recalculationisis to
to press
press the
the F9
F9 key.
key.
(This isis often
(This often called
called the
the "recalculate"
"recalculate" key.)
key.) You
You can
can also
alsoclick
click the
the Calculate
Calculate Now
Now
button or
button or the
the Calculate
CalculateSheet
Sheetbutton,
button, both
bothon on the
theFormulas
Formulas ribbon
ribbon to tothe
the right.
right.
Calculate Now
Calculate Now recalculates
recalculates all
all formulas
formulasin inthe
the workbook,
workbook, whereas
whereas Calculate
Calculate
Sheet recalculates
Sheet recalculates only
onlythe
theformulas
formulas in inthe
the active
active worksheet.
worksheet.
Using AutoSum
Using AutoSum to
to Create
Create Row
Row and/or
and/or Column
Column Sums
Sums

TheSUM
The SUM function
function isis used
usedsoso often
often to
to sum
sum across
across rowsrows or
or columns
columnsthatthataa button
button
(the SS button)
(the button) isis available
availableto to automate
automate thethe procedure.
procedure.In In fact,
fact, this
thisbutton
buttonisisononthe
the
Home ribbon
Home ribbon andand the
theFormulas
Formulas ribbon
ribbon (see
(see the
the two
two screenshots
screenshotsto to the
the right).
right).To
To
illustrate its
illustrate its use,
use, suppose
suppose youyou have
have aatable
table of
of numbers
numbers in in some
somerectangular
rectangular range.
range.
You want the row sums to appear to the right of the range,
You want the row sums to appear to the right of the range, and you want the and you want the
columnsums
column sums to toappear
appear below
below the
therange.
range. This
This isis easy.
easy.

To produce
To produce row
row and
andcolumn
column sums
sums with
with the
the AutoSum
AutoSumbutton:
button:

Select the
Select the range(s)
range(s) where
whereyou
youwant
want the
the sums
sums to
to appear
appear and
and click
clickthe
the AutoSum
AutoSum
button.
button.
Notethat
Note that ifif you
you select
select multiple
multiple cells,
cells, you
you get
getthe
the sums
sums automatically.
automatically. IfIf you
you select
select aa
single cell
single cell (such
(such asas when
when you
youhave
have aasingle
singlecolumn
columnof of numbers
numbers to to sum),
sum), you
you will
will be
be
shown the
shown thesum sum formula
formula for
for your
your approval
approval andand you
you will
will have
have to
to press
press Enter
Enter to
to
actually enter
actually enter it.it.

Tryit!
Try it! Use
Usethe
theAutoSum
AutoSum button
button to
to fill
fill in
in the
the row
row and
and column
column sums
sumsininthe
the blue
blue cells
cells
to the
to the right,
right, including
includingthe
the darker
darker blue
bluecell cell which
which should
shouldshow
show the
thesum
sum ofof all
all the
the
data.
data.

Other Uses
Other Uses of
of the
the AutoSum
AutoSum Dropdown
Dropdown

Notethat
Note that there
there isis aadropdown
dropdown next
next to
to the
the AutoSum
AutoSum button.
button. IfIf you
you want
wantaa sum,
sum, click
click
directly on
directly the SS button.
onthe button.Alternately,
Alternately, you
you can
can click
clickon
on the
thedropdown
dropdown for for other
other
options, including
options, including Average,
Average, Count
Count Numbers,
Numbers, Max,Max, and
and Min
Min (see
(seeto to the
theright).
right).
51 94 15 7
37 6 2 41
13 83 29 88
73 64 46 32
38 11 3 80
Step-by-Step Evaluation
Step-by-Step Evaluation of
of aa Formula
Formula

Excel formulas
Excel formulas can can get
get very
verylong
long and
and complex.
complex.Often Often you
you get
geterrors
errors from
from complex
complex
formulas because of incorrect syntax, such as missing or
formulas because of incorrect syntax, such as missing or misplaced parentheses. misplaced parentheses.
IfIf you
you get
get such
such an
an error
error ---- and
and everyon
everyondoes
does sooner
sooner or or later
later ----you
you need
need toto stare
stareat
at
itit long
long enough
enoughto to find
find the
the error
error and
and then
then fix
fix it.
it.But
But even
even formulas
formulas with
withcorrect
correct
syntax can
syntax can have
have errors
errorsthat thatlead
lead to
towrong
wrong values.
values. ForFor this
this reason,
reason, Excel
Excel has
has anan
Evaluate Formula button in the Formula Auditing group
Evaluate Formula button in the Formula Auditing group of the Formulas ribbon, of the Formulas ribbon,
shown to
shown to the
theright.
right. ItItlets
letsyou
you"walk
"walk through"
through" each each part
part ofof the
the formula
formula to
tocheck
check
that itit isis working
that workingas as intended.
intended.

Try it!
Try it! The
The formulas
formulas in in column
column NN involve
involve nested
nestedIF IF functions,
functions, based
basedon onthe
the
customer data
customer data inin columns
columns LL and and M, M, to
to see
see ifif the
the customer
customer isis categorized
categorizedas as
Excellent, Good,
Excellent, Good, or or Ok.
Ok.CanCan you
you understand
understandthe theformula
formula in inany
anyof of these
these cells?
cells? To
To
say the
say theleast,
least, there
there isis aalot
lot going
going on.on. Put
Putyour
your cursor
cursor in in any
any formula
formula cellcell in
incolumn
column
NN and
and click
click the
theEvaluate
Evaluate button.
button. As As shown
shown in in the
the first
firstdialog
dialog box
box below,
below, thethe first
first
cell reference
cell referenceisis underlined.
underlined.IfIf you you click
click on
onEvaluate,
Evaluate, you you will
will see
seewhat
what this
this cell
cell
referenceevaluates
reference evaluates to. to. Alternatively,
Alternatively, you youcan
canclick click the
theStep
Step In
In button
button to toseesee the
the
evaluationmore
evaluation more explicitly
explicitly(as(as in
in the
the second
second dialog
dialogbox box below),
below), and
andyouyoucan canthen
then
click Step
click Step Out
Out button
button to to return
returnto to the
the overall
overall evaluation.
evaluation.IfIf you
youclick
click Evaluate
Evaluate
again, you
again, youwill
will see
see whether
whether the thefirst
firstcondition
condition isis TrueTrueor or False.
False.ByBy continuing
continuing to to
click Evaluate,
click Evaluate, youyoucancanseesee how
how allall parts
parts of
of the
the formula
formula evaluate.
evaluate.
Person Status Last Invoice Category
1 D 859.69 Ok
2 B 3297.24 Excellent
3 A 2130 Good
4 C 1574.8 Ok
5 D 3729.78 Good
6 B 1400.08 Ok
7 D 2593.58 Ok
8 C 3827.74 Good
9 A 3047 Excellent
10 D 1802.1 Ok
11 A 3346.41 Excellent
12 A 1728.75 Ok
13 C 1421.96 Ok
Referencing aa Different
Referencing Different Worksheet
Worksheet

Mostof
Most of your
your formulas
formulas willwill probably
probably reference
reference cells
cells or
or ranges
ranges on
on the
thesame
sameworksheet
worksheet
as the formulas. However, it is perfectly legal to reference cells or ranges
as the formulas. However, it is perfectly legal to reference cells or ranges in other in other
worksheets of
worksheets of the
the same
same workbook
workbookor or even
even other
other workbooks.
workbooks. The The easiest
easiestway way to
toenter
enter
such an
such an external
external cell
cell or
or range
range isis to
to point
point to
to the
the cell
cell or
or drag
drag the
the range
range in
in the
the usual
usual way.
way.
When you
When you do
do so,
so, an
anindication
indication of of the
theexternal
external worksheet
worksheet and/or
and/or workbook
workbookwill will appear
appear
in the
in theformula.
formula.

For example,
For example, the
the formula
formula inin the
the blue
bluecell
cell to
to the
the right
rightaverages
averages the
the invoices
invoices in
in the
the
previous worksheet.
previous worksheet.ItsIts syntax
syntax isis

=AVERAGE('Evaluating aa formula'!M13:M25)
=AVERAGE('Evaluating formula'!M13:M25)

When referencing
When referencing aarange
range in
in aadifferent
different worksheet,
worksheet, thethe sheet
sheet name
name andand an
an
exclamation point must precede the address. If the sheet name
exclamation point must precede the address. If the sheet name has any "illegal" has any "illegal"
characters (usually
characters (usuallyspaces),
spaces), the
the sheet
sheetname name must
must be be enclosed
enclosedin insingle
single quotes.
quotes. Note
Note
that the
that the formula
formula in
in the
the green
green cell
cell to
to the
theright,
right, which
whichreferences
references thetheIF
IF worksheet,
worksheet, hashas
nosingle
no singlequotes
quotes around
around thethe sheet
sheet name
namebecause
becausethere
thereare
areno
no illegal
illegal characters
charactersin inIF.
IF.

Once you
Once you start
start referencing
referencing other
other worksheets
worksheets in in aa formula,
formula, all
all references,
references, even
even toto
ranges in
ranges in the
the same
same worksheet
worksheetas as the
the formula,
formula, will
will have
havesheet
sheet references.
references.Check
Check outout
theformula
the formulain in the
thered
redcell
cell to
to the
the right.
right.This
This formula
formula was was created
createdby bydragging
dragging the
the
invoices range
invoices range on on the
the other
other sheet
sheet and
and then
then pointing
pointingto to cell
cell O4
O4 on on this
thissheet.
sheet. (You
(You could
could
then manually
then manually change
change 'External
'External Formula
Formula References'!O4
References'!O4 to to O4
O4to to simplify
simplify the
the
formula.)
formula.)

Referencing aa Different
Referencing Different Workbook
Workbook

You can
You can also
alsoreference
referenceanother
another workbook.
workbook. For
For example,
example, the
thefollowing
following formula
formula
references aa range
references range in
in another
another workbook
workbook called
called Sample
SampleData.xlsx.
Data.xlsx.Its
Its syntax
syntax isis

=AVERAGE([Sample Data.xlsx]Data!$I$4:$I$53)
=AVERAGE([Sample Data.xlsx]Data!$I$4:$I$53)

The name
The name of
of the
the workbook
workbook isis in
in square
square brackets,
brackets, followed
followed byby the
the sheet
sheetname
name and
and anan
exclamation point, and then the address. Note that this formula was created
exclamation point, and then the address. Note that this formula was created while the while the
file Sample
file Sample Data.xlsx
Data.xlsx was
was open.
open. WhenWhen the
theSample
Sample Data.xlsx
Data.xlsxfile
filewas
was closed,
closed, the
the formula
formula
changed to
changed to

=AVERAGE('D:\MyExcel
=AVERAGE('D:\My Excel Files\[Sample
Files\[Sample Data.xlsx]Data'!$I$4:$I$53)
Data.xlsx]Data'!$I$4:$I$53)

Now the
Now the path
path to
to the
the file
file isis included,
included, with
with everything
everything before
before the
theexclamation
exclamation point
point in in
singlequotes.
single quotes. This
This means
meansthat thatyou
youcan
canhave
have aa formula
formula that
thatreferences
references aa file
file that
that isis not
not
even open!
even open!
You have
You have to
to be
be careful
careful in in such
such situations,
situations, however.
however. IfIf youyoumove,
move, rename,
rename, or or delete
delete the the
referencedfile,
referenced file, the
the formula
formulawill will no
no longer
longer work.
work.ItIt won't
won't necessarily
necessarily showshow an an error,
error, but
but
it won't work. Of course, if the referenced file is deleted, you are out
it won't work. Of course, if the referenced file is deleted, you are out of luck. If it is of luck. If it is
renamedor
renamed or moved
moved to to aa different
different folder,
folder, you
youwillwill need
need toto change
changethe the file
file reference
reference(the (the
path and/or
path and/or the
thefile
file name)
name) in inthe
the formula
formula appropriately.
appropriately. Alternatively,
Alternatively, you you can
can click
click the
the
Edit Links
Edit Links button
button on onthethe Data
Data ribbon
ribbon and
and fix
fix the
the link
link there.
there. IfIf you
you don't
don't fix
fix the
theformula,
formula,
Now the
Now the path
path to
to the
the file
file isis included,
included, with
with everything
everything before
before the
theexclamation
exclamation point
point in in
singlequotes.
single quotes. This
This means
meansthat thatyou
youcan
canhave
have aa formula
formula that
thatreferences
references aa file
file that
that isis not
not
even open!
even open!

You have
You have toto be
be careful
careful in in such
such situations,
situations, however.
however. IfIf you youmove,
move, rename,
rename, or or delete
delete the the
referencedfile,
referenced file, the
the formula
formulawillwill no
no longer
longer work.
work.ItIt won't
won't necessarily
necessarily showshow an an error,
error, but but
itit won't
won'twork.
work.Of Of course,
course, ifif the
thereferenced
referenced filefile isis deleted,
deleted, you
you areare out
outofof luck.
luck. IfIf itit isis
renamedor
renamed or moved
moved to to aa different
different folder,
folder, you
youwill will need
need toto change
changethe the file
file reference
reference(the (the
path and/or
path and/or thethefile
file name)
name) in inthe
the formula
formula appropriately.
appropriately. Alternatively,
Alternatively, you you can
can click
click the the
Edit Links
Edit Links button
button on onthethe Data
Data ribbon
ribbon and
and fix
fix the
the link
link there.
there. IfIf you
you don't
don't fix
fix the
theformula,
formula,
thenext
the next time
timeyouyouopenopen thethe file,
file, you
you will
will be
bewarned
warned about about aamissing
missing link.
link.
Average invoice 2366.087 Tax rate 1.05
Avg invoice with tax 2484.391

Average score 75
General Information
General Information About
About Charts
Charts

Nothingtells
Nothing tells aa story
story better
better than
than aawell-designed
well-designed chart,
chart, and
andExcel
Excel provides
provides aahuge
huge
number of charting possibilities. In fact, whole books have been devoted
number of charting possibilities. In fact, whole books have been devoted to Excel to Excel
charts. ItItisisimpossible
charts. impossibleto to cover
cover all
all of
of the
thepossibilities
possibilities here,
here, but
butthe
the next
next feww
feww
worksheetsillustrate
worksheets illustratehow
how to
to create
createbasic
basic charts
charts quickly
quickly and
and easily.
easily.

IfIf you
youhave
havecreated
created aalot
lotof
of charts
charts in
in Excel
Excel 2003
2003 but
but you
you are
arenew
new to
to Excel
Excel 2007
2007 (or
(or
2010), you
2010), you will
will see
see some
some significant
significant changes.
changes. The
The most
most important
important are
are listed
listed
below.
below.
1.To
1. To create
create aa chart,
chart, use
usethetheInsert
Insert ribbon.
ribbon.ItIt has
has aa Charts
Charts group
group with
with buttons
buttons for
for
Column, Line,
Column, Line, Pie,
Pie, Bar,
Bar, Area,
Area, Scatter,
Scatter, and
and Other
Other Charts.
Charts. Each
Eachbutton
button has
has aa
dropdown list
dropdown list for
for the
the various
varioussubtypes.
subtypes.
2.Once
2. Onceyou
youhave
haveaa chart
chart and
and then
then select
select itit (that
(that is,
is, click
click somewhere
somewhereon onit),
it), you
you
get three
get threenew
new Chart
ChartTools
Tools tabs:
tabs: Design,
Design, Layout,
Layout, and andFormat
Format (see
(see below).
below).TheThe
corresponding ribbons
corresponding ribbons have
have plenty
plenty of of buttons
buttons for for modifying
modifying an anexisting
existing chart.
chart.
Probably the
Probably the most
most important
important of of these
theseisisthe
the Select
Select Data
Databutton
buttononon the
theDesign
Design
ribbon, which
ribbon, which lets
lets you
you edit
edit the
thedata
data range(s)
range(s) the thechart
chartisisbased
basedon.
on. Of
Of course,
course, youyou
can experiment
can experiment with
withthe
the other
other buttons,
buttons, andand you you can
can also
also experiment
experimentby byright-
right-
clickingvarious
clicking various parts
parts of
of aa chart
chart to
to see
seethethe possibilities.
possibilities.

Youcould
You couldspend
spend aalot lot of
of time
time reading
reading thick
thick chapters
chapters or
or even
evenentire
entirebooks
books onon Excel
Excel
charts, but
charts, but itit isis better
better toto experiment
experiment on onyour
your own.
own.You
Youcancanlearn
learn aalot
lotby
by
modifying an
modifying an existing
existingchart
chartininvarious
various ways.
ways.You
Youmight
might not
not learn
learn some
someof of the
the
esoteric tools
esoteric tools thisthis way,
way, but
butyou
youwill
will learn
learn the
the most
most frequently
frequently used
used tools.
tools.
Creating aa Chart
Creating Chart the
the Easy
Easy Way
Way

Probably the
Probably the easiest
easiest waywayto to create
create aachart,
chart, based
based on
on aa given
given data
data set,
set, isis to
to select
select
at least part of the data set, including the data to be charted and the
at least part of the data set, including the data to be charted and the labels for labels for
thehorizontal
the horizontal axis,
axis, ifif any,
any, and
and select
select one
oneof
of the
the chart
chart types
types from
from the
the Insert
Insert
ribbon. You
ribbon. You will
will almost
almostcertainly
certainly want
wantto
to modify
modify the
the resulting
resulting chart,
chart, but
but thisthis
usually provides
usually provides aagood
good start.
start.

Theexample
The example to to the
the right
right isis typical.
typical.The
Thegoal
goal isis to
to create
create aacolumn
columnchart
chartof of
monthlysales,
monthly sales, so
so you
you can
can select
select the
the entire
entire blue
blue range
range toto the
the right
right(including
(including the
the
labels in
labels in the
the top
toprow),
row), and
and select
select aacolumn
columnchartchart(of (of the
thefirst
firstsubtype)
subtype) from
from the
the
Insert ribbon.
Insert ribbon.The The only
only change
change thatthat was
wasthen
then made
madeto to the
thechart
chartwas
was toto delete
delete the
the
legend. Excel
legend. Excel guessed
guessed correctly
correctly thatthatititshould
should chart
chart one
oneseries,
series, Sales,
Sales, and
andthat
thatitit
should use
should usethe
thedates
dates in in column
column KK as aslabels
labels for
for the
the horizontal
horizontal axis.
axis.

Creating aa Chart
Creating Chart with
with Multiple
Multiple Series
Series

Here isis another


Here another example.
example. The The red
red range
range to tothe
the right
rightincludes
includes monthly
monthly sales
sales of of two
two
products, and the goal is to create a line chart that contains both
products, and the goal is to create a line chart that contains both series. In this series. In this
case, you
case, you can
canselect
selectthe
theentire
entire red
red range,
range, including
includingcolumn
column K, K, and
and select
select aa line
line
chart with
chart with markers
markers from
from thethe Insert
Insert ribbon.
ribbon. ThisThistime
time the
the legend
legendisisappropriate.
appropriate.
However, there
However, thereisis no
no title
title above
above the
thechart
chartby bydefault,
default, soso you
you can
can add
add the
theoneone
shown (from the Chart Tools Layout ribbon). Note that the horizontal
shown (from the Chart Tools Layout ribbon). Note that the horizontal axis titles axis titles
arevertical
are vertical bybydefault.
default. IfIf you
you would
would rather
rather have
have them
them atatan
an angle,
angle, right-click
right-click the
the
horizontal axis
horizontal axis and
and select
select thethe option
optionto to format
format thethe alignment
alignment of ofthe
theaxis
axis labels.
labels.

The Important
The Important Role
Role of
ofSeries
Series in
in aa Chart
Chart

Themost
The mostimportant
important concept
concept forfor charts
charts isis aa series.
series.Every
EveryExcel
Excel chart
chart contains
contains one
one
or more series. In the first chart above, there is one series, Sales.
or more series. In the first chart above, there is one series, Sales. In the second In the second
chart, there
chart, thereare
are two
two series,
series, Sales1
Sales1 andand Sales2.
Sales2. Typically,
Typically, each
eachseries
seriesisisaa column
column ofof
data, with
data, withaa label
label atat the
the top,
top, although
althoughseries
seriesare aresometimes
sometimes in in rows,
rows, asasin
inthe
the
green right
green right to
to the
theright
right (which
(which isis simply
simplythe the transpose
transpose ofof the
the previous
previous example).
example).
Again, you can select the entire green range and insert a line chart.
Again, you can select the entire green range and insert a line chart. Excel guesses Excel guesses
correctly that
correctly that the
the data
dataseries
series are
arein inrows,
rows, notnot columns.
columns. But
But what
what ififititmakes
makes the
the
wrong guess?
wrong guess? See
See the
the next
next example.
example.
Again, you
Again, you can
canselect
selectthe
the entire
entire green
greenrange
range and
and insert
insertaa line
line chart.
chart. Excel
Excel guesses
guesses
correctly that the data series are in rows, not columns. But what if it makes
correctly that the data series are in rows, not columns. But what if it makes the the
wrong guess?
wrong guess? See
See the
the next
next example.
example.

Switching the
Switching the Roles
Rolesof
ofRows
Rows and
and Columns
Columns and
and Changing
Changing the
the Chart
Chart Type
Type

Thedata
The dataset
setinin the
the gray
grayrange
rangetoto the
the right
right contains
contains sales
sales data
data for
for four
four products
products in in
six regions.
six regions. You
You cancan select
select the
the entire
entire data
datarange,
range, including
including the
the row
row and and column
column
labels, and
labels, andinsert
insertaa line
line chart.
chart.What
What are
arethethe series?
series? By
By default,
default, Excel
Excel creates
creates aalineline
for each
for eachproduct,
product, with
withthetheregion
region labels
labels on
on the
thehorizontal
horizontal axis.
axis.That
Thatis, is, itit guesses
guesses
that the
that the columns
columns are are the
the series.
series. Suppose
Supposeyou youwould
would rather
rather have
have thethe rows
rows as asthe
the
series, that
series, thatis,
is, you
you would
wouldrather
rather have
haveaa line
line for
for each
each region.
region. This
This isis easy.
easy.

To switch
To switch the
the roles
roles of
of rows
rows and
and columns:
columns:

Click anywhere
Click anywhere ononthe
the chart
chart and
and click
click the
the Switch
Switch Row/Column
Row/Column button
button on
on the
the
ChartTools
Chart Tools Design
Designribbon.
ribbon.

Tryit!
Try it! Create
Createaa column
column chart
chart (of
(of the
the first
first subtype)
subtype) for
for the
the monthly
monthly data
data in
inthe
the
orangerange
orange range to
to the
the right,
right, where
where each
each series
series corresponds
corresponds to to aa time
time series
series for
for aa
particular product.
particular product.
Sometimesyou
Sometimes youchange
change your
your mind
mind and
and want
wantto
to have
have another
another chart
chart type.
type.

To change
To change the
the chart
chart type:
type:

Click anywhere
Click anywhere on onthe
the chart
chart and
and click
click the
the Change
Change Chart
Chart Type
Type button
button on
on the
theChart
Chart
Tools Design
Tools Design ribbon.
ribbon.

Tryit!
Try it! Change
Changethe the column
column chart
chart you
you just
just created
createdto
to aaline
line chart.
chart. Make
Make sure
sure each
each
series still corresponds to a product.
series still corresponds to a product.

Modifying the
Modifying the Data
Data Series
Series

Byselecting
By selectingthe
theappropriate
appropriatedatadata and
and then
then inserting
inserting aa chart,
chart, you
you usually
usuallyget
get what
what
you want. But suppose you create a chart and it doesn't chart the right data.
you want. But suppose you create a chart and it doesn't chart the right data. You You
can either
can either delete
delete this
this chart
chart and
andstart
start over,
over, or
or you
youcan
can modify
modify the
thedata
dataseries.
series.

To modify
To modify the
the data
data series
seriesin
inan
an existing
existing chart:
chart:

Click anywhere
Click anywhere on onthe
the chart
chart and
and click
click the
the Data
Data Series
Series button
button on on the
the Chart
Chart Tools
Tools
Design ribbon.
Design ribbon. This
This brings
brings up
up aadialog
dialog box
box (see
(seeto
to the
theright)
right) with
with the
the series
series
chartedon
charted on the
theleft
left and
and the
the data
dataused
used for
for the
thehorizontal
horizontal axis
axis labels
labels on
on the
the right.
right.
You can then edit (or delete) any of these.
You can then edit (or delete) any of these. 6000

Try it!
it! The
The line
line chart
chart to
toright
right was
was created
created bybyselecting
selectingthe
the tan
tanrange
rangeto
to the
theright,
right, 5000
Try
without the
without thelabels
labels to
tothe
the left
left or
or in
inthe
the top
top row.
row. There
There are
are three
three problems:
problems: (1)
(1) the
the 4000
months should be labels on the horizontal axis; (2) the two
months should be labels on the horizontal axis; (2) the two "junk" series "junk" series
shouldn'tbe
shouldn't be part
part of
of the
the chart;
chart; and
and(3)(3) the
thetwo
two sales
sales series
series should
shouldbebe named
namedby by 3000
Click anywhere
Click anywhere on onthe
the chart
chart and
and click
click the
the Data
Data Series
Series button
button on on the
the Chart
Chart Tools
Tools
Design ribbon.
Design ribbon. This
This brings
brings up
up aadialog
dialog box
box (see
(seeto
to the
theright)
right) with
with the
the series
series
chartedon
charted on the
theleft
left and
and the
the data
dataused
used for
for the
thehorizontal
horizontal axis
axis labels
labels on
on the
the right.
right.
You can
You can then
then edit
edit(or
(or delete)
delete) any
anyofof these.
these. 6000
5000
Try it!
Try it! The
The line
line chart
chart to
toright
right was
was created
created by byselecting
selectingthe the tan
tanrange
rangetoto the
theright,
right,
without the
without thelabels
labels to
tothe
the left
left or
or in
inthe
the top
top row.
row. There
There areare three
three problems:
problems: (1)
(1) the
the 4000
months should
months should bebe labels
labelson
onthethehorizontal
horizontal axis;
axis; (2)
(2) the
thetwo
two "junk"
"junk" series
series
shouldn'tbe
shouldn't be part
part of
of the
the chart;
chart; and
and(3)(3) the
thetwo
two sales
sales series
series should
shouldbebe named
namedby by 3000
thelabels
the labels at
at the
thetop
top of
of columns
columns NN and and O.O. Open
Open the the Data
Data Series
Series dialog
dialog box
box and
and fix
fix
these problems.
these problems. 2000
1000
0
1 2

Scatter Charts
Scatter Charts

Onechart
One charttype
type that
thatworks
works aa bit
bitdifferent
differentfrom
fromthe
theothers
others isis the
the scatter
scatter chart.
chart.This
This
type of
type of chart
chart isis useful
useful for
for detecting
detecting relationships
relationships between
between two two variables,
variables, such
such as
as
height (inches) and weight (pounds) in the data to the
height (inches) and weight (pounds) in the data to the right. right.

To create
To create the
the chart,
chart, you
you can
canselect
select the
the orange
orange range
range toto the
the right
right and
and insert
insert aa
scatter chart
scatter chart of
of the
thefirst
firstsubtype.
subtype.You Youcan
canthen
thenchange
change the
the title,
title, delete
deletethethe
legend, and add horizontal and vertical axis titles, as shown. If
legend, and add horizontal and vertical axis titles, as shown. If you then open you then open the
the
DataSeries
Data Series dialog
dialogbox,
box, you
you will
will see
see that
that there
thereisisone
one series,
series, Weight.
Weight. However,
However, ifif
you click
you clickthe
the Edit
Edit button
button for
for this
this series,
series, you
youwill
will see
see that
that there
there isis aaY-series
Y-series and
and an
an
X-series.
X-series.
Bydefault,
By default, when
whenyou youselect
select two
two columns
columns for for aa scatter
scatter chart,
chart, the the data
data in
in the
the
rightmostcolumn,
rightmost column, in in this
this case
caseWeight,
Weight, isis the
the Y-series
Y-series (it
(it goes
goes on onthe
the vertical
vertical axis),
axis),
andthe
and the other
other isis the
the X-series
X-series (it
(it goes
goes on
on the
thehorizontal
horizontal axis).
axis). IfIfyou
youwant
want them
them
reversed, you
reversed, you have
have to to go
go through
throughthethe Data
Data Series
Series dialog
dialog box.
box.

Tryit!
Try it! Starting
Starting with
with the
thescatter
scatter chart
chart to
to the
the right,
right, change
changeititso
so that
that Height
Height isis on
on
thevertical
the vertical axis
axis and
and Weight
Weightisis on
on the
thehorizontal
horizontal axis.
axis. (You
(You will
will have
have to
to change
change thethe
axis titles manually.)
axis titles manually.)
Month Sales
Jan-09 $8,627 Sales
Feb-09 $5,343
$10,000
Mar-09 $6,244 $9,000
Apr-09 $9,451 $8,000
May-09 $6,698 $7,000
Jun-09 $6,752 $6,000
$5,000
Jul-09 $5,985
$4,000
Aug-09 $5,586 $3,000
Sep-09 $8,476 $2,000
Oct-09 $9,191 $1,000
Nov-09 $7,242 $0
Dec-09 $8,277 Jan-09 Mar-09 May-09 Jul-09 Sep-09 Nov-09

Month Sales1 Sales2


Jan-09 $8,627 $8,452 Monthly Sales of Two Products
Feb-09 $5,343 $6,801
$12,000
Mar-09 $6,244 $5,497
Apr-09 $9,451 $10,329 $10,000
May-09 $6,698 $5,995 $8,000 Sales1
Jun-09 $6,752 $8,103 Sales2
Jul-09 $5,985 $6,386 $6,000
Aug-09 $5,586 $5,047 $4,000
Sep-09 $8,476 $8,641
$2,000
Oct-09 $9,191 $10,696
Nov-09 $7,242 $6,914 $0
Dec-09 $8,277 $9,004 Jan-09 Apr-09 Jul-09 Oct-09

Month Jan-09 Feb-09 Mar-09 Apr-09 May-09 Jun-09 Jul-09 Aug-09 Sep-09
Sales1 $8,627 $5,343 $6,244 $9,451 $6,698 $6,752 $5,985 $5,586 $8,476
Sales2 $8,452 $6,801 $5,497 $10,329 $5,995 $8,103 $6,386 $5,047 $8,641

Monthly Sales of Two Products


$12,000
$10,000
$8,000 Sales1
Sales2
$6,000
$4,000
Monthly Sales of Two Products
$12,000
$10,000
$8,000 Sales1
Sales2
$6,000
$4,000
$2,000
$0
Jan-09 Apr-09 Jul-09 Oct-09

Product1 Product2 Product3 Product4 $5,000


Region1 $4,749 $1,637 $1,002 $4,212 $4,500
Region2 $1,187 $2,259 $4,236 $2,711 $4,000
Region3 $2,973 $3,779 $4,419 $1,881 $3,500
Region4 $4,570 $3,677 $3,682 $3,020 $3,000 Pro
Region5 $3,494 $1,040 $4,637 $1,808 $2,500 Pro
Region6 $2,158 $4,644 $1,296 $3,920 $2,000 Pro
Pro
$1,500
$1,000
$500
$0
Region1 Region2 Region3 Region4 Region5 Region6

Jan-09 Feb-09 Mar-09 Apr-09 May-09 Jun-09


Product1 $1,191 $2,116 $1,328 $2,136 $2,352 $4,156
Product2 $3,147 $3,751 $3,954 $4,314 $4,194 $2,442
Product3 $2,959 $3,628 $3,628 $4,529 $2,548 $4,415
Product4 $1,740 $2,733 $4,310 $2,228 $1,313 $2,675
Product5 $4,730 $1,058 $4,800 $2,156 $2,518 $2,917
Product6 $4,970 $4,947 $2,707 $1,134 $1,787 $1,927

Month Junk1 Junk2 Sales1 Sales2


Jan-09 29 27 $2,625 $4,139
Feb-09 74 23 $1,776 $4,955
Mar-09 78 59 $2,537 $2,379
Apr-09 6 12 $4,360 $4,631
May-09 69 2 $3,636 $2,413
Jun-09 62 3 $2,135 $4,187

6000
5000
4000
Column L
3000 Column M
6000
5000
4000
Column L
3000 Column M
Column N
2000
Column O
1000
0
1 2 3 4 5 6

Person Height Weight


1 60 155 Height versus weight
2 61 162
300
3 62 162
4 63 162 250
5 63 164 200
6 65 168
Weight

150
7 70 175
8 72 199 100
9 72 215 50
10 76 241
0
58 60 62 64 66 68 70 72 74 76 78
Height
ucts

Sales1
Sales2

Oct-09 Nov-09 Dec-09


$9,191 $7,242 $8,277
$10,696 $6,914 $9,004
Product1
Product2
Product3
Product4

n4 Region5 Region6
ght

0 72 74 76 78
Changing the
Changing the Location
Location of
of aa Chart
Chart

AA chart
chart can
can be
be placed
placed in
inone
one of
of twotwo locations:
locations: on on aa worksheet
worksheet (probably
(probablythethe
worksheet that contains the data the chart is based on), or on
worksheet that contains the data the chart is based on), or on a separate chart a separate chart
sheet(a
sheet (asheet
sheet that
that has
has no
norows
rows or or columns,
columns, only
only aa chart).
chart). Some
Some people
peopleprefer
prefer the
the
first option,
first option, and
andothers
others prefer
prefer the
thesecond.
second. ItIt isis totally
totallyaa matter
matter of
oftaste.
taste. When
When you
you
create aa chart
create chartfrom
from the
theInsert
Insert ribbon,
ribbon, the thechart
chartisisplaced
placed on
on the
the worksheet
worksheet with
with
the data by default. However, it is easy to
the data by default. However, it is easy to move it. move it.

To change
To change the
the location
location of
of aachart:
chart:

Click anywhere
Click anywhere on
onthe
the chart,
chart, and
andclick
click the
the Move
Move Chart
Chart button
button on
on the
the Chart
Chart Tools
Tools
Design ribbon
Design ribbon(see
(see below).
below). You
You can
can then
then choose
choose from
fromthe
the above
above two
two options.
options.

Tryit!
Try it! Move
Move the
the chart
chart to
to the
the right
right to
to aa separate
separate chart
chart sheet.
sheet. (This
(This chart
chart sheet
sheet will
will
have a name like Chart1, but you can rename it.) Then move the
have a name like Chart1, but you can rename it.) Then move the chart back to chart back to
this worksheet.
this worksheet. Note
Note that
that when
when youyou move
move the
the chart
chart back
back to
to this
this worksheet,
worksheet, the
the
chart sheet
chart sheet will
will disappear.
disappear.
Month Sales
Jan-09 $8,627 Sales
Feb-09 $5,343
$10,000
Mar-09 $6,244
$9,000
Apr-09 $9,451
$8,000
May-09 $6,698
$7,000
Jun-09 $6,752
$6,000
Jul-09 $5,985
$5,000
Aug-09 $5,586
$4,000
Sep-09 $8,476
$3,000
Oct-09 $9,191
$2,000
Nov-09 $7,242
$1,000
Dec-09 $8,277
$0
Jan-09 Mar-09 May-09 Jul-09 Sep-09 Nov-09
Nov-09
Modifying an
Modifying an Existing
Existing Chart
Chart

Once you
Once you create
create aachart
chartand
and ensure
ensurethat that ititcharts
charts the
thecorrect
correct series,
series, you
youare
are
usually still not finished. Just about everything you see on the
usually still not finished. Just about everything you see on the chart can bechart can be
modified to
modified to suit
suit your
your taste
taste(or
(or tell
tell the
the story
story better).
better).Here
Here are
are some,
some, butbut certainly
certainly
not all,
not all, of
of the
the changes
changes youyou can
can make:
make:

1.Add,
1. Add, delete,
delete, or
or change
change thethechart
chart title.
title.
2.Add,
2. Add, delete,
delete, or
or change
change thetheaxis
axis titles.
titles.
3.Add,
3. Add, delete,
delete, or
or move
movethe thelegend.
legend.
4.Change
4. Change the
thescale,
scale, font,
font, alignment,
alignment, or or number
number format
format of of the
the axis
axis labels.
labels.
5. Add, delete, or change the gridlines, e.g., make them
5. Add, delete, or change the gridlines, e.g., make them lighter. lighter.
6.Add
6. Add data
data labels
labels to
to points
points on
onthe
the chart.
chart.
7.Change
7. Change the
thebackground
background color
color of
of the
theplot
plotarea
area (the
(the inner
inner part
part of
of the
thechart).
chart).
To make
To makethese
theseoror other
other changes,
changes, you
you can
can use use the
the buttons
buttons on
on the
the Chart
ChartTools
Tools
ribbons, or
ribbons, or you
you can
can right-click
right-click on
on the
the part
partof ofthe
thechart
chartyou
youwant
want to
tochange
change to
to get
get
aa context-sensitive
context-sensitive menu.
menu. From
Fromthere,
there, itit isis aamatter
matter of
of experimenting.
experimenting.

Tryit!
Try it! The
The top
topchart
chart to
to the
theright
right was
was created
created by byselecting
selecting the
the blue
blue range
range to
to the
the
right and
right and inserting
inserting aascatter
scatter chart
chart of
ofthe
the first
first subtype.
subtype. Then
Then ititwas
was modified
modified quite
quite
aa lot
lot to
to produce
produce the
thebottom
bottom chart.
chart.Repeat
Repeat this
thisexercise
exercisebyby creating
creatingthe the default
default
scatter chart
scatter chart and
and then
then modifying
modifying ititto
to look
look like
likethe
the finished
finishedversion.
version.

Hints: IfIf you


Hints: you click
click aa point
pointon on aa scatter
scatter chart,
chart, you
youselect
select all
all of
of the
the points.
points.But
But you
you
can select
can select aa single
single point
point byby clicking
clicking twice
twice in
inaa row
row (not
(notdouble-clicking,
double-clicking, but but
clickingonce
clicking onceand
andthen
then clicking
clicking again.)
again.) However,
However, thisthis still
still didn't
didn't help
helpwith
withthe
the label
label
for March at the top. The only data labels you can add to points
for March at the top. The only data labels you can add to points on a scatter chart on a scatter chart
arethe
are theX-values
X-values oror the
the Y-values.
Y-values. The
Thegoal
goal here
herewaswas to
to add
add thethemonth
month label
label to
tothe
the
point near
point near thethetop,
top, soso you
you have
have to
to add
add aatext
textboxbox (from
(from the the Insert
Insert ribbon).
ribbon).

Clearly, you
Clearly, youcan
can spend
spend aa lot
lot of
of time
time modifying
modifying aa chart.chart. Sometimes
Sometimes ititisis time
timewell
well
spent, and
spent, and sometimes
sometimesitit isn't.
isn't. You
You have
have toto use
use common
common sense.sense. The
The best
best advice
adviceis:
is:
Make sure
Make sureitit looks
looks professional,
professional, make
make sure
sure itit tells
tellsthe
the intended
intended story
storyclearly,
clearly, and
and
keep itit simple!
keep simple! Usually
Usuallysimple
simplecharts
charts look
look best
bestand and tell
tell the
thestory
storybest.
best.
Sales1 Sales2
$8,627 $23,919 Sales2
$5,343 $19,507
$40,000
$6,244 $34,377
$9,451 $30,285 $35,000
$6,698 $19,673 $30,000
$6,752 $21,007 $25,000
Sales2
$5,985 $16,644
$20,000
$5,586 $21,022
$15,000
$8,476 $23,928
$9,191 $31,403 $10,000
$7,242 $25,333 $5,000
$8,277 $28,071 $0
$5,000 $6,000 $7,000 $8,000 $9,000 $10,000

Sale of product 2 versus sales of product 1


35,000.0 March
March
32,500.0
30,000.0
Product 2 ($1000s)

27,500.0
25,000.0
22,500.0
20,000.0
17,500.0
15,000.0
5,000 6,000 7,000 8,000 9,000 10,000
Product 1 ($1000s)
Sales2

$10,000

ct 1

9,000 10,000
Two Essential
Two Essential Excel
Excel Functions
Functions

Thereare
There aremany
many"essential"
"essential" Excel
Excel functions,
functions, so
so you
you might
mightbebe surprised
surprised that
that this
this
tutorial singles out two of them, IF and VLOOKUP, in this section.
tutorial singles out two of them, IF and VLOOKUP, in this section. This was doneThis was done
purposely. IfIf you
purposely. you ever
ever work
work ininany
anybusiness
business that
that relies
relies heavily
heavilyon
on Excel,
Excel, and
and the
the
chances are
chances are that
that you
you will,
will, you
you will
will use
usethese
thesetwo
two functions
functions constantly.
constantly.More
More than
than
almost any
almost any other
other Excel
Excel functions,
functions, they
theyenable
enable you
you toto capture
capture business
businesslogic,
logic, so
sothey
they
are absolutely indispensable. As one Excel guru, Bill Jelen, stated in
are absolutely indispensable. As one Excel guru, Bill Jelen, stated in one of his one of his
books, he
books, hewould
would never
never hire
hire anyone
anyone who
who couldn't
couldn'tdo do VLOOKUPs
VLOOKUPs with
with their
their eyes
eyes
closed!
closed!
Introductionto
Introduction toExcel
Excel Functions
Functions

Mostof
Most of the
the formulas
formulas you
you create
create inin Excel
Excel include
includeone
one or
or more
more built-in
built-inExcel
Excel
functions, such as SUM, IF, VLOOKUP, and many, many others.
functions, such as SUM, IF, VLOOKUP, and many, many others. Probably no Probably no one,
one,
noteven
not eventhe the programmers
programmers at atMicrosoft,
Microsoft, isis familiar
familiar with
with all
all of
of the
theExcel
Excelfunctions,
functions,
because there
because there are
are hundreds
hundreds of
of them,
them, but
but you
you should
should strive
strive to
to learn
learn as
as many
many asas
you can.
you can.

Excel'sfunctions
Excel's functions are
are grouped
groupedinto
into categories,
categories, including
includingFinancial,
Financial, Math
Math&& Trig,
Trig,
Date&& Time,
Date Time, and
and others.
others.You
Youcan
canseeseethese
these categories
categories in
inthe
theFunction
Function Library
Library
group on
group onthe
the Formulas
Formulas ribbon.
ribbon. The
The following
followingfew
few worksheets
worksheets illustrate
illustrate some
some ofof
the more useful Excel functions in the various categories.
the more useful Excel functions in the various categories.
The names
The names ofof these
these functions
functions are
are capitalized
capitalized in
in this
this tutorial,
tutorial, but
butthis
this isis just
just for
for
emphasis. They
emphasis. Theyareare not
not case
casesensitive.
sensitive.You
Youcan
can enter
enter SUMSUM oror sum,
sum, for
for example,
example,
withthe
with the same
same result.
result.

Some functions
Some functionsare
are soso useful
useful that
that Excel
Excel automatically
automatically applies
appliesthem
themtoto selected
selected
ranges (when
ranges (when atat least
leasttwo
two cells
cells are
areselected).
selected). The
Theresults
results are
are displayed
displayedin in the
the
status bar at the bottom of the screen. If you right-click any blank space
status bar at the bottom of the screen. If you right-click any blank space on the on the
status bar,
status bar, you
you can
can check
check the
thefunctions
functions you
youwant
want to
to be
be visible.
visible.

Try it!
Try it! Select
Selectany
anyparts
parts of
of the
the data
data to
to the
the right
rightand
andlook
look at
at the
thestatus
statusbar.
bar. Then
Then
right-click the status bar and select more options if you want
right-click the status bar and select more options if you want them. them.
Bob Mary Jack
10 6 5
5 11 7
13 10 6
2 15 19
9 5 20
18 16 19
18 15 1
2 19 10
18 14 6
Finding Help
Finding Help for
forExcel
Excel Functions
Functions

IfIf you
youhavent
haventusedused the
the ffxx (Insert
(Insert Function)
Function) button
button located
locatedjustjusttoto the
the left
left of
of the
the
formulabar,
formula bar, you
you should
shouldgive give itit aatry.
try. ItIt not
not only
onlylists
lists all
all of
of the
the functions
functionsavailable
available
in Excel
in Excel (by
(bycategory),
category), but
butititalsoalso leads
leads you you through
through thethe use
use ofof them.
them. As As an
an
example, suppose you know there is an Excel function
example, suppose you know there is an Excel function that calculates payments that calculates payments
on aaloan,
on loan, but
but you
you are
are not
notsure sure what
whatits its name
name isis or
or how
how to to use
use it.
it. You
You can
can proceed
proceed
as follows.
as follows.

To use
To use the
the ffxxbutton:
button:

Select aablank
Select blank cell
cell where
where you you want
wantthe
the function
functionto to go.
go.Press
Press the
the ffxx button
button and
and
select the category that seems most appropriate (Financial in
select the category that seems most appropriate (Financial in this case). Scan this case). Scan
through the
through the list
list for
for aa likely
likely candidate
candidate and
and select
select itit (try
(tryPMT).
PMT). At Atthis
this point,
point, you
youcan
can
get help,
get help, or
or you
you cancan click
click the
theOKOK button
buttonand
andenter
enter the the appropriate
appropriate arguments
arguments forfor
thefunction
the function (interest
(interest rate,
rate, term,
term, and
and principal,
principal, the
the latter
latter expressed
expressed as as aa negative
negative
number).
number).
Somepeople
Some peopleuseuse the
the ffxx button
button as
as aa "crutch"
"crutch" every
every timetime they
they want
wanttoto enter
enter an
an
Excel function.
Excel function. You
You probably
probablyshouldn't
shouldn't dodothis
this for
for functions
functions you
youknow
know well
well
becauseitittakes
because takes more
more time.time. However,
However,ititisis great
great for
for learning
learning how
how to
to use
use functions
functions
you are
you areless
less familiar
familiar with.
with.

Tryit!
Try it! Use
Usethe
the ffxxbutton
buttonto to help
helpyou
youdetermine
determinethe
the function
functionin
in the
the blue
blue cell
cell to
to the
the
right. (Scroll
right. (Scroll to
tothe
the right
rightto
to see
seethe
the correct
correctformula.)
formula.)

Youcan
You can get
get the
the same
same help
help from
fromthe the Formulas
Formulas ribbon,
ribbon, asas shown
shown totothe
the right.
right.(This
(This
screenshot is from Excel 2010, but it is about the same in Excel
screenshot is from Excel 2010, but it is about the same in Excel 2007). There are 2007). There are
buttons for
buttons for the
the various
various categories
categories of of functions,
functions, so so you
you can
can scan
scan the
the list
list for
for any
any
category very
category very quickly.
quickly. In
In fact,
fact, this
this isis aa good
good way way to
to expand
expandyouryour repertoire
repertoire of of
Excel functions.
Excel functions. Just
Just look
look atat any
anyof of the
thelists
lists and
and ask
ask for
for help
help on
onany
anythat
thatlooklook
interesting.
interesting.
Payments for the purchaser of a new car

Amount financed $15,000


Annual interest rate 4.90%
Term (number of months financed) 36
Monthly payment
Payment

Note that
Note that the
the PMT
PMT function
function isis
category. In
category. In general,
general, itit has
has five
fiv
the last
the last two
two areare optional
optional andand
here. There
here. There isis aa minus
minus sign
sign ne
n
because it is paid, not
because it is paid, not receive receive
$448.89

Notethat
Note that the
thePMTPMT function
functionisisin inthe
thefinancial
financial
category.In
category. In general,
general, itit has
has five
five arguments,
arguments, but
but
thelast
the lasttwo
two areare optional
optional andandaren't
aren'tneeded
needed
here. There
here. Thereisis aa minus
minus sign
sign next
nexttoto Principal
Principal
because it is paid, not received.
because it is paid, not received.
Basic IF
Basic IF Function
Function

IF functions
IF functions are
are very
very useful
useful for
for performing
performinglogic,
logic, and
and they
they vary
vary from
from simple
simpleto
to
complex. This worksheet provides a few typical examples.
complex. This worksheet provides a few typical examples.
To enter
To enter aabasic
basic IF
IF function:
function:

Enter the
Enter theformula
formula =IF(condition,expression1,expression2),
=IF(condition,expression1,expression2), where where condition
condition isisany
any
condition that
condition thatisis either
either true
true or
or false,
false, expression1
expression1 isis the
the value
value of
of thetheformula
formula ifif the
the
condition isis true,
condition true, and
and expression2
expression2 isis the
the value
valueof
of the
the formula
formula ifif the
the condition
conditionisis
false.
false.

AA simple
simpleexample
exampleisis =IF(A1<5,10,NA).
=IF(A1<5,10,NA). Note Notethat
that ifif either
either of
of the
the expressions
expressions isis aa
label (as
label (asopposed
opposed to
to aa numeric
numeric value),
value), itit should
should be
be enclosed
enclosed in in double
double quotes.
quotes.
Tryit!
Try it! Enter
Enter appropriate
appropriate IF
IF formulas
formulas in
in columns
columns M
M and
andN.
N. (Scroll
(Scroll to
to the
the right
right for
for
answers.)
answers.)

Nested IF
Nested IF Functions
Functions

SometimesIF
Sometimes IF functions
functions are
arenested.
nested.For
For example,
example, there
there might
might bebe three
three
possibilities, depending
possibilities, dependingon onwhether
whether the
the value
value in
in cell
cell A1
A1 isis negative,
negative, zero,
zero, or
or
positive. AA nested
positive. nestedIF IF formula
formulacan
can then
thenbe
be used
used as
asfollows.
follows.

To use
To use nested
nested IF
IF functions:
functions:

Enter the
Enter theformula
formula
=IF(condition1,expression1,IF(condition2,expression2,expression3)). IfIf
=IF(condition1,expression1,IF(condition2,expression2,expression3)).
condition1 isis true,
condition1 true, the
therelevant
relevant value
valueisis expression1.
expression1.Otherwise,
Otherwise, condition2
condition2 isis
checked.IfIf ititisis true,
checked. true, the
the relevant
relevant value
value isis expression2.
expression2. Otherwise,
Otherwise, the
therelevant
relevant
valueisis expression3.
value expression3.

Anexample
An exampleisis =IF(A1<0,10,IF(A1=0,20,30)).
=IF(A1<0,10,IF(A1=0,20,30)). Suppose
Suppose this
thisformula
formulaisisentered
entered in in
cell B2.
cell B2. Then
Then ifif A1
A1 contains
contains aanegative
negative number,
number, B2
B2contains
contains 10.
10. Otherwise,
Otherwise, ifif A1
A1
contains 0,
contains 0, B2
B2 contains
contains 20.
20.Otherwise
Otherwise (meaning
(meaningthat
that A1
A1must
mustcontain
contain aapositive
positive
value), B2
value), B2 contains
contains 30.
30.

Tryit!
Try it! Use
Useaa nested
nested IF
IF function
function to
to get
get the
thegrades
grades in
in column
column M.
M. (Scroll
(Scroll to
to the
the right
right
for answers.)
for answers.)

IF Functions
IF Functions with
with Logical
Logical AND
AND or
or OR
OR Conditions
Conditions

Sometimesmore
Sometimes morecomplex
complex conditions
conditions (AND
(AND or
or OR
ORconditions)
conditions) are
are useful
useful in
in IF
IF
functions. They are not difficult once you know the syntax.
functions. They are not difficult once you know the syntax.
To use
To use an
anAND
AND condition
condition in
in an
anIF
IF function:
function:
IF Functions
IF Functions with
with Logical
Logical AND
AND or
or OR
OR Conditions
Conditions

Sometimesmore
Sometimes morecomplex
complex conditions
conditions (AND
(AND or
or OR
ORconditions)
conditions) are
are useful
useful in
in IF
IF
functions.They
functions. They are
are not
not difficult
difficult once
onceyou
youknow
know the
the syntax.
syntax.

To use
To use an
anAND
AND condition
condition in
in an
anIF
IF function:
function:

Enter the
Enter theformula
formula =IF(AND(condition1,condition2),expression1,expression2).
=IF(AND(condition1,condition2),expression1,expression2).
This results in expression1 ifif both
This results in expression1 both condition1
condition1 and
and condition2
condition2 are
are true.
true.Otherwise,
Otherwise,
itit results
results in
in expression2.
expression2.

Notethe
Note the syntax.
syntax.The
Thekeyword
keyword AND
ANDisis followed
followedby bythe
the conditions,
conditions, separated
separated by
by aa
comma and enclosed within parentheses. Also, note that more
comma and enclosed within parentheses. Also, note that more than two than two
conditions could
conditions could be
beincluded
includedin
inthe
theAND,
AND, allall separated
separated by
by commas.
commas.

Tryit!
Try it! Use
Usean
an IF
IF function
functionwith
with an
anAND
ANDcondition
condition to
tofill
fill in
in the
the green
green range
range to
to the
the
right. Make sure you use double quotes for labels.(Scroll to the right for
right. Make sure you use double quotes for labels.(Scroll to the right for answers.) answers.)

To use
To use an
anOR
OR condition
conditionin
inan
an IF
IF function:
function:

Enter the
Enter theformula
formula =IF(OR(condition1,condition2),expression1,expression2).
=IF(OR(condition1,condition2),expression1,expression2). This This
resultsin
results in expression1
expression1 ifif either
either condition1
condition1 or
or condition2
condition2 isis true
true (or
(or ifif both
both are
are
true). Otherwise,
true). Otherwise, itit results
results in
in expression2.
expression2.

Again, more
Again, more than
than two
two conditions
conditionscould
could be
be included
included in
in the
the OR.
OR.

Tryit!
Try it! Use
Usean an IF
IF function
functionwith
with an
anOR
OR condition
condition to
to fill
fill in
in the
thebonuses
bonusesin
in column
columnP.P.
(Scroll to
(Scroll to the
theright
right for
for answers.)
answers.)

Youcan
You can even
evenhave
have AND
AND and
and ORORconditions
conditions in
in the
the same
same formula.
formula. AA typical
typical
example isis =IF(OR(AND(B3>=10,C3>=15),D3<50),1000,2000).
example =IF(OR(AND(B3>=10,C3>=15),D3<50),1000,2000). For For example,
example, ifif cells
cells
B3, C3,
B3, C3, and
and D3
D3 have
have values
values 12,
12, 10,
10, and
and 40,
40, this
this returns
returns 1000
1000 because
becausethethesecond
second
condition (D3<50)
condition (D3<50) isis true,
true, even
even though
though the
theAND
ANDcondition
condition isis false.
false.The
The key
keyto to
writing (and
writing (and reading)
reading) such
such complex
complex formulas
formulas isis to
to pay
paycareful
careful attention
attention to
to the
the
parentheses.
parentheses.
For each product, if the end inventory is less than or equal to 50 units,
enough units are ordered to bring stock back up to 200; otherwise, no
units of that product are ordered

Product End inventory Order placed (yes or no)? # of units ordered


1 100
2 40
3 20
4 70

Each student gets an A (if score is 90 or above), S for satisfactory (if score
if 60 or above but less than 90) or U for unsatisfactory if score is below 60

Student Score Grade


1 70
2 95
3 55
4 80
5 60
6 90

Investor sells stock only if its price has gone up three consecutive days
(including the current day)

Day Price change Sell (yes or no)?


1 Up
2 Down
3 Up
4 Up
5 Up
6 Down

Any student who scores at least 95 on any of the exams gets a bonus
which is 1% of their total score.

Student Exam 1 Exam 2 Exam 3 Exam 4 Bonus


1 87 83 83 80
2 77 72 74 97
3 80 95 79 75
4 82 87 96 88
5 78 94 81 79
6 75 83 80 72
Order placed?
no
yes
yes
no

Grade
S
A
U
S
S
A
Sell?

No
No
Yes
No

Bonus
0
3.2
3.29
3.53
0
0
# ordered
0
160
180
0
General Information
General Information about
about Lookup
Lookup Tables
Tablesand
and VLOOKUP
VLOOKUPFunction
Function

Lookuptables
Lookup tables are
areuseful
useful when
whenyou youwant
want to
tocompare
compare aa particular
particular value
value to to aa set
set of
of
values, and depending on where your value falls, assign a given answer.
values, and depending on where your value falls, assign a given answer. For For
example, you
example, you might
might have
have aatax
tax table
tablethat
thatshows,
shows, for for any
any income,
income, what
whatthe the
corresponding tax
corresponding tax is.
is.There
There are
are two
two versions
versions ofof lookup
lookuptables,
tables, vertical
vertical (VLOOKUP)
(VLOOKUP)
andhorizontal
and horizontal (HLOOKUP).
(HLOOKUP). Because
Because they
they are
arevirtually
virtually identical
identical except
except that
that
vertical goes down and horizontal goes across, only the VLOOKUP function isis
vertical goes down and horizontal goes across, only the VLOOKUP function
discussed here.
discussed here. Besides,
Besides, VLOOKUP
VLOOKUPisis usedused much
muchmore morefrequently
frequently than
than HLOOKUP.
HLOOKUP.

TheVLOOKUP
The VLOOKUP function
function takes
takes three
threearguments
arguments plus
plus an
an optional
optional fourth
fourth argument:
argument:

1.The
1. Thevalue
value to
tobe
be compared
compared
2.AA lookup
2. lookuptable,
table, with
with the
the values
values to
to be
be compared
compared with with always
always in
in the
the lef
lef column
column
3. The
3. Thecolumn
column number
number of of the
the lookup
lookup table
table where
whereyou youfind
findthe
the answer
answer
4.TRUE
4. TRUE oror FALSE
FALSE(which
(which isis TRUE
TRUEby bydefault
default ifif omitted)
omitted)

That is,
That is, the
thegeneral
general syntax
syntax is:
is:

=VLOOKUP(value,lookup table,column
=VLOOKUP(value,lookup table,column #,TRUE
#,TRUE or
or FALSE)
FALSE)

Theoptional
The optional fourth
fourthargument
argumentrequires
requires some
some explanation.
explanation.The The default
default value,
value,
TRUE, indicates
TRUE, indicates you
you want
want toto see
see where
where the the lookup
lookupvalues
values fits
fits in
in aa range
range of of values,
values,
those in the first column of the lookup table. (Microsoft calls this
those in the first column of the lookup table. (Microsoft calls this looking for an looking for an
approximate match.)
approximate match.) In
In this
this case,
case, the
thefirst
firstcolumn
columnof of the
thelookup
lookuptabletable must
must bebe inin
ascending order.
ascending order. However,
However, ifif the
the fourth
fourth argument
argument isis FALSE,
FALSE, this
thismeans
meansyou youare
are
lookingfor
looking for an
an exact
exact match
match in inthe
the first
first column
column of of the
thelookup
lookup table.
table.In In this
this case,
case, itit
doesn't matter whether the first column is in ascending
doesn't matter whether the first column is in ascending order or not. order or not.

Becausethe
Because the VLOOKUP
VLOOKUPfunction
function isis often
oftencopied
copieddown
down aacolumn,
column, itit isis usually
usually
necessaryto
necessary to make
make the
thesecond
second argument
argumentan an absolute
absolute reference.
reference. The
Theeasiest
easiest way
way
to do this is to give the lookup table a range name such as LookupTable
to do this is to give the lookup table a range name such as LookupTable (range (range
names are
names arealways
always treated
treatedas
as absolute
absolutereferences),
references), but
but aarange
rangename
nameisisnot not
necessary.
necessary.

Looking Up
Looking Upaa Value
Value in
in aa Range
Range (an
(an Approximate
Approximate Match)
Match)

Themost
The mostcommon
commonuse use of
of aa lookup
lookup table
table isis when
when youyou want
wantto to see
seewhere
where aavalue
value
fits in
fits in aa range
rangeof of values.
values. Then
Then thethe fourth
fourth argument
argument can can be
beomitted
omitted because
becauseits its
default value
default value isis TRUE.
TRUE.Suppose
Suppose you you want
wantto to assign
assignletter
letter grades
grades toto students
students based
based
on a straight scale: below 60, an F: at least 60 but below 70,
on a straight scale: below 60, an F: at least 60 but below 70, a D; at least 70 but a D; at least 70 but
below 80,
below 80, aaC;
C; atatleast
least8080 but
but below
below 90,
90, aaB; B; and
and 90
90 oror above,
above, anan A.
A. The
The first
first data
data
set to
set tothe
the right
right shows
shows how
how youyouwould
would setsetthis
this up.
up.The
The comparison
comparison column
column in inthe
the
lookuptable
lookup tablestarts
starts at at00 (the
(the lowest
lowest grade
grade possible)
possible) and
and then
thenrecords
records thethecutoff
cutoff
scores 60
scores 60through
through 90. 90.

Theformula
The formulain in the
thedarker
darker blue
blue cell
cellto
to the
theright
right isis
=VLOOKUP(L39,$O$39:$P$43,2), which
=VLOOKUP(L39,$O$39:$P$43,2), which isis copied
copied down
down column
column M.M. This
This formula
formula
compares the value in L39 (67) to the values in column O and chooses
compares the value in L39 (67) to the values in column O and chooses the largest the largest
valueless
value less than
thanoror equal
equal to
to it.
it. This
Thisisis60.
60. Then
Thenbecause
because thethe third
thirdargument
argumentin in the
the
default value
default value isis TRUE.
TRUE.Suppose
Suppose you you want
wantto to assign
assignletter
letter grades
grades toto students
students based
based
on aastraight
on straight scale:
scale: below
below 60,60, an
anF:
F: at
at least
least60
60 but
but below
below 70,70, aaD;
D; at
atleast
least 70
70 but
but
below 80, a C; at least 80 but below 90, a B; and 90 or above, an
below 80, a C; at least 80 but below 90, a B; and 90 or above, an A. The first dataA. The first data
set to
set tothe
the right
right shows
shows how
how youyouwould
would set setthis
this up.
up.The
The comparison
comparison column
column in inthe
the
lookuptable
lookup tablestarts
starts atat00 (the
(the lowest
lowest grade
grade possible)
possible) and
and then
thenrecords
records the
thecutoff
cutoff
scores 60
scores 60through
through 90. 90.

Theformula
The formulain in the
thedarker
darker blue
blue cell
celltoto the
theright
right isis
=VLOOKUP(L39,$O$39:$P$43,2), which
=VLOOKUP(L39,$O$39:$P$43,2), which isis copied
copied downdown column
column M. M. This
This formula
formula
comparesthe
compares the value
value in
in L39
L39 (67)
(67) to
to the
thevalues
values in
in column
column OOand
and chooses
chooses the
the largest
largest
value less than or equal to it. This is 60. Then because the third argument
value less than or equal to it. This is 60. Then because the third argument in the in the
VLOOKUP function
VLOOKUP function isis 2,
2, the
the score
score reported
reported in in M39
M39 comes
comes from
from the
the second
second
columnof
column of the
the lookup
lookuptable
tablenext
nexttoto 60,
60, namely,
namely, D. D.

Tryit!
Try it! For
For the
theorders
orders to to the
the right,
right, create
create aalookup
lookup table
tablein
incolumns
columns OOand
andP,P, and
and
VLOOKUP functions
VLOOKUP functionsin incolumn
column M. M.Assume
Assume therethere isis quantity
quantity discount
discount pricing:
pricing: for
for
orders less
orders lessthan
than 300
300 units,
units, the
the unit
unit price
price isis $3;
$3; for
for orders
orders of
of at
atleast
least 300
300 units
units but
but
less than
less than 400,
400, the
the unit
unitprice
price isis $2.50;
$2.50; for
for orders
orders of of 400
400 units
units or
or more,
more, the
the unit
unit
price isis $2.
price $2. (Scroll
(Scroll to
to the
the right
right for
for the
theanswer.)
answer.)

Looking for
Looking for an
an Exact
Exact Match
Match

In the
In the examples
examples above,
above, itit wouldn't
wouldn't make
make sense
sense toto look
look for
for anan exact
exact match
match
because there usually isn't one. For example, a typical score
because there usually isn't one. For example, a typical score such as 67 such as 67 does
does not
not
exactly match
exactly match any
any of ofthe
thevalues
values in
in the
the first
first column
column of ofthe
the lookup
lookuptable.
table. However,
However,
there are
there aremany
many cases
cases when
when ititdoes
does make
make sense
sense toto look
lookfor
for an an exact
exact match.
match.Then
Then
there are
there arethree
three things
things toto remember.
remember.(1) (1) The
The fourth
fourtharguments
arguments isis notnot optional;
optional; itit
must be
must be FALSE.
FALSE. (2)
(2) The
Thefirst
firstcolumn
columnof of the
the lookup
lookuptable
table doesn't
doesn'thavehavetoto be
bein
in
ascendingorder;
ascending order; ititcan
can be,
be, but
but order
order doesn't
doesn't matter.
matter. (3)
(3) IfIf no
no exact
exactmatch
matchexists,
exists,
thefunction
the function returns
returns an an error.
error.

Tryit!
Try it! Use
Useaa VLOOKUP
VLOOKUP function
function inin column
columnM M to
to find
findthe
the gradepoints
gradepoints for
for each
each
student, using
student, using the
the lookup
lookup table
table in
in columns
columns OOand
and P.P.What
What happens
happenswith
with Williams?
Williams?

Notethat
Note that the
the grades
grades in in column
columnOO ofof the
the lookup
lookup table
table are
are in
in the
the natural
natural order,
order,
but they are not in Excels A-Z sort order. Therefore, FALSE must
but they are not in Excels A-Z sort order. Therefore, FALSE must be entered as be entered as the
the
fourth argument
fourth argument in in the
theVLOOKUP
VLOOKUP function.
function. Try
Try ititwithout
without the
the fourth
fourth argument
argument toto
confirmthat
confirm that you
you get
get incorrect
incorrect results.
results.
Student Score Grade Lookup table
1 67 D 0 F
2 72 C 60 D
3 77 C 70 C
4 70 C 80 B
5 66 D 90 A
6 81 B
7 93 A
8 59 F
9 90 A

Order # Units sold Total cost Lookup table


1 373
2 475
3 459
4 441
5 238
6 349
7 344
8 203

Student Grade Gradepoints Grade Gradepoints


Adams B A 4
Davis A- A- 3.7
Edwards C+ B+ 3.3
Johnson B- B 3
Myers B+ B- 2.7
Smith A C+ 2.3
Thomson C C 2
Williams D C- 1.7
Total cost Lookup table
$932.50 0 $3.00
$950.00 300 $2.50
$918.00 400 $2.00
$882.00
$714.00
$872.50
$860.00
$609.00
Useful Functions
Useful Functions for
for Summarizing
Summarizing Data
Data

Thenext
The next few
few worksheets,
worksheets, II discuss
discuss some
some less
less common
common functions
functionsfor for counting,
counting,
summing, and averaging. These include the frequently
summing, and averaging. These include the frequently used SUM, AVERAGE,used SUM, AVERAGE,
COUNT, and
COUNT, and COUNTA
COUNTA functions,
functions, plus
plus aa few
fewothers.
others. Although
Althoughthe the latter
latter are
are less
less
common and
common and are
areconsidered
considered more
moreadvanced,
advanced, they they are
are extremely
extremely useful
useful in in certain
certain
situations.For
situations. For example,
example, youyou will
will learn
learn how
how toto count,
count, sum,
sum, or or average,
average, butbutonlyonly
over rows
over rows that
that satisfy
satisfy certain
certainconditions.
conditions. The The functions
functionsfor for doint
dointthis
this all
all contain
containIF IF
in their
in their name,
name, such
suchasas COUNTIF
COUNTIF andand SUMIFS.
SUMIFS. TheThe last
lastfunction
function inin this
this section,
section,
SUMPRODUCT, does
SUMPRODUCT, does exactly
exactly what
whatits its name
nameimplies:
implies: itit sums
sums products.
products. ItItisis
absolutelyindispensable
absolutely indispensablein inmany
many business
business models.
models.
SUM function
SUM function

TheSUM
The SUM function
function isis probably
probablythe
the most
most used
used Excel
Excel function
function of
of all.
all.ItIt sums
sums all
all
values in one or more ranges.
values in one or more ranges.
To use
To use the
theSUM
SUM function:
function:

Enter the
Enter theformula
formula =SUM(range),
=SUM(range), where where range
range isisany
any range.
range.This
This sums
sums the
the
numeric values
numeric values in
inthe
the range.
range. IfIf there
there are
are any
any nonnumeric
nonnumeric or or blank
blank cells
cellsin
inthis
this
range, they
range, they are
are ignored.
ignored.

Actually, ititisis possible


Actually, possible to
to include
include more
more than
than one
onerange
rangein inaa SUM
SUM formula,
formula,
separated by
separated by commas.
commas. (This
(This can
can also
also be
be done
done with
with the
the COUNT,
COUNT, COUNTA,
COUNTA,
AVERAGE, MAX,
AVERAGE, MAX, and andMIN
MIN functions.)
functions.) For
For example,
example, =SUM(B5,C10:D12,Revenues)
=SUM(B5,C10:D12,Revenues)
isis allowable
allowable (where
(where Revenues
Revenues isis thethe name
namefor for some
somerange).
range).The
Theresult
resultisis the
the sum
sum
of the numeric values in all of these ranges combined. Again, if any
of the numeric values in all of these ranges combined. Again, if any cells in any of cells in any of
theseranges
these ranges are arenonnumeric
nonnumeric or or blank,
blank, they
theyare
are ignored.
ignored.

Here isis aashortcut,


Here shortcut, which
whichworks
works for
for any
any function
function that
that takes
takes multiple
multiple ranges,
ranges,
separated by commas. Put your finger on the Ctrl key and then
separated by commas. Put your finger on the Ctrl key and then drag the drag the ranges,
ranges,
oneafter
one after the
theother.
other.The
Thecommas
commas will
will be
be entered
entered for
for you
youautomatically.
automatically.

Tryit!
Try it! Use
Usethe
theSUM
SUM function
function in
in the
theblue
blue cell
cell to
to the
theright
right to
to calculate
calculatethe
the total
total of
of
all costs.
all costs.

AVERAGE function
AVERAGE function

TheAVERAGE
The AVERAGE function
function averages
averages all
all of
ofthe
thenumeric
numeric cells
cells in
in aa range.
range.
To use
To use the
theAVERAGE
AVERAGE function:
function:

Enter the
Enter theformula
formula =AVERAGE(range)
=AVERAGE(range) where
where range
range isis any
any range.
range.This
This produces
produces the
the
average of the numeric values in the range.
average of the numeric values in the range.
Notethat
Note that the
the AVERAGE
AVERAGE function
function ignores
ignores labels
labelsand
and blank
blank cells.
cells. So,
So, for
for example,
example, ifif
therange
the rangeC3:C50
C3:C50includes
includes scores
scores forfor students
students on
on aatest,
test, but
but cells
cellsC6C6 and
and C32
C32 are
are
blank because these students havent yet taken the test, then
blank because these students havent yet taken the test, then =AVERAGE(C3:C50) =AVERAGE(C3:C50)
averages only
averages only the
thescores
scores for
for the
the students
students whowho took
took the
the test.
test. (It
(It does
does not
not
automaticallyaverage
automatically average inin 0s
0s for
for the
the two
two who
whodidnt
didnttake
takethethe test.)
test.)
Tryit!
Try it! Use
Usethe
theAVERAGE
AVERAGE function
function in
in the
the two
two red
redcells
cells to
to the
the right
rightto
to calculate
calculate the
the
averages indicated.
averages indicated. (For
(For the
the formula
formulain inthe
thebottom
bottom red
red cell,
cell, you
you will
will have
have to
to
replicatethe
replicate the exam
exam scores
scores in in column
column M M and
and make
makesome
some changes.)
changes.)
Table of costs for units produced in one month (along side)
for use in another month (along top)

Feb Mar Apr May


Jan $3,100 $4,800 $6,500 $3,400
Feb $5,600 $4,100 $7,000
Mar $5,000 $3,500
Apr $6,500

Total cost

Student ID Exam score Average (only for students who took the exam)
1533 68
8031 74
9859 80 Average (giving 0s to students who were absent)
9106 63
3535 72
8192 Absent
6102 85
6774 70
7558 64
314 72
9082 81
2397 75
2517 80
2432 73
6016 63
5269 80
4847 88
6537 71
9922 73
4525 71
1491 71
7897 68
4088 82
166 76
7925 75
6405 81
802 76
2931 83
7625 67
2628 67
5417 92
7804 72
3994 69
394 85
8847 78
7855 81
8668 Absent
3738 77
5534 70
6965 71
8863 69
8762 73
6466 60
6100 76
1878 74
5970 67
9691 62
8666 77
4865 91
6198 81
8554 87
6753 76
9574 77
3891 81
8186 Absent
1306 73
6835 83
3136 59
4938 74
4807 74
4421 78
COUNT, COUNTA,
COUNT, COUNTA, COUNTBLANK
COUNTBLANK Functions
Functions

TheCOUNT
The COUNT function
functioncounts
counts all
all of
of the
the cells
cells in
inaa range
range with
with numeric
numeric values.
values.TheThe
COUNTA function counts all nonblank cells in a range. For example, if cells
COUNTA function counts all nonblank cells in a range. For example, if cells A1, A2,A1, A2,
andA3
and A3contain
contain Month,
Month, 1,
1, and
and 2,
2, respectively,
respectively, then
then =COUNT(A1:A3)
=COUNT(A1:A3) returns
returns 2,
2,
whereas =COUNTA(A1:A3)
whereas =COUNTA(A1:A3) returns
returns 3. 3.

Notethat
Note that Excel
Excel isis somewhat
somewhatinconsistent
inconsistentin
inthe
the terms
terms itit uses
uses on
on the
thestatus
status bar.
bar. IfIf
you select
you select aa range
range and
and look
look at
at the
thestatus
statusbar,
bar, itit will
will show
show "Count"
"Count" and
and"Numerical
"Numerical
Count." The
Count." The first
first corresponds
corresponds to toCOUNTA,
COUNTA, and
andthe the second
second corresponds
corresponds to
to COUNT.
COUNT.

To use
To use the
theCOUNT
COUNT function:
function:

Enter the
Enter theformula
formula =COUNT(range),
=COUNT(range), where where range
range isis any
any range.
range. This
This returns
returns the
the
number of
number of numeric
numeric values
values in
in the
the range.
range.
To use
To use the
theCOUNTA
COUNTA function:
function:

Enter the
Enter theformula
formula =COUNTA(range),
=COUNTA(range), where
where range
range isis any
anyrange.
range. This
Thisreturns
returns the
the
number of nonblank cells in the range.
number of nonblank cells in the range.
TheCOUNTBLANK
The COUNTBLANKfunction
functioncounts
counts all
all blank
blank cells
cells in
inaa range.
range.

To use
To use the
theCOUNTBLANK
COUNTBLANK function:
function:

Enter the
Enter theformula
formula =COUNTBLANK(range),
=COUNTBLANK(range), where
where range
range isis any
any range.
range.This
This returns
returns
thenumber
the number of of blank
blankcells
cells in
in the
therange.
range.

Tryit!
Try it! Use
Usethe
theCOUNT,
COUNT, COUNTA,
COUNTA, and
and COUNTBLANK
COUNTBLANK functions
functions to
to fill
fill in
in the
theblue
blue
cells to
cells tothe
the right.
right.
Student Exam score Number enrolled
1 62
2 73
3 74 Number who took exam
4
5 77
6 57 Number who were absent
7 67
8 90
9 77
10 83
11 71
12 75
13 72
14 82
15 68
16 86
17 77
18 68
19 86
20
21 80
22 81
23 84
24 71
25 76
26 81
27 99
28 72
29 78
30 67
31 89
32 70
33 77
34
35 83
36 74
37 87
38 75
39 86
40 77
41 73
42 74
43 79
44 80
45 77
46 72
47 77
48 71
49 70
50 68
51 79
52 75
53 80
54 73
55 61
56 62
57 68
58 92
59 85
60 77
61 79
62 86
63 83
64 83
65 76
66 89
67 72
68 69
69 66
70 71
71 80
72 61
Background on
Background on _IF
_IF Functions
Functions

There are
There are several
several Excel
Excel functions
functions that
that allow
allow you
you to
to count
count values,
values, or
or sum
sum oror
average values, subject to conditions. Until Excel 2007, this was possible
average values, subject to conditions. Until Excel 2007, this was possible only only for
for
aa single
single condition,
condition, such
such asas all
all people
people younger
younger than
than 3535 years
years old,
old, and
and there
there were
were
only two
only two functions
functions available,
available, COUNTIF
COUNTIF and
and SUMIF.
SUMIF. InIn response
responseto to customer
customer
demand, Microsoft
demand, Microsoft added
added four
four new
new functions
functions in
inExcel
Excel 2007:
2007: AVERAGEIF
AVERAGEIF (for(for aa
single condition), and COUNTIFS, SUMIFS, and AVERAGEIFS
single condition), and COUNTIFS, SUMIFS, and AVERAGEIFS (for multiple (for multiple
conditions). These
conditions). Theseare
are all
all handy
handy functions,
functions, and
andyou
youshould
should learn
learn how
how toto use
use
them.
them.

COUNTIF Function
COUNTIF Function

TheCOUNTIF
The COUNTIF function
function counts
countsall
all values
values in
in aaspecified
specified range
range that
that satisfy
satisfy aa certain
certain
condition.
condition.
To use
To use the
theCOUNTIF
COUNTIF function:
function:

Enter the
Enter theformula
formula =COUNTIF(criterion_range,condition)
=COUNTIF(criterion_range,condition)in inany
anycell,
cell, where
where
condition is any expression that evaluates to TRUE or FALSE. This counts
condition is any expression that evaluates to TRUE or FALSE. This counts all all values
values
in criterion_range
in criterion_range that
thatsatisfy
satisfy the
the condition.
condition.

Thecondition
The condition can
can be
be tricky
trickytoto specify.
specify.IfIf you
you want
wantaa specific
specific value,
value, such
suchas as Male,
Male,
you can specify it easily as "Male" (quotes required), or
you can specify it easily as "Male" (quotes required), or you can use a cell you can use a cell
reference such
reference such asasQ3.
Q3. Also,
Also, ifif you
you want
want aa specific
specific inequality,
inequality, such
such asasyounger
younger than than
20, you
20, you can
can specify
specify itit literally
literallyas as "<20"
"<20" (again,
(again, quotes
quotes required).
required). But But ifif you
you want
want itit
to be
to be younger
younger than
than the
thevalue
value in in cell
cell Q4,
Q4, you
you need
need toto piece
piece itit together
together as as aa literal
literal
part, "<", and a variable part, whatever is in cell Q4. The correct
part, "<", and a variable part, whatever is in cell Q4. The correct syntax is "<"&Q4. syntax is "<"&Q4.
Theampersand
The ampersand (&) (&) symbol
symbol connects
connects (concatenates)
(concatenates) the the two
two pieces.
pieces.ForFor example,
example,
ifif you
you want
wanttoto know
know the thenumber
number of of students
students who
who areare older
older than
than 20,20, the
thecorrect
correct
formulaisis=COUNTIF(M4:M75,">"&Q4).
formula =COUNTIF(M4:M75,">"&Q4).

Tryit!
Try it! Use
UseCOUNTIF
COUNTIF in in the
theblue
blue cell
cell to
to the
theright
right to
to find
findthe
the number
number of of students
students
who scored
who scoredat at least
least as
as high
high as
as the
theexam
exam score
score cutoff
cutoff value
value above
above it.
it. (Scroll
(Scroll to
tothe
the
right for
right for the
the answer.)
answer.)

SUMIF and
SUMIF and AVERAGEIF
AVERAGEIF Functions
Functions

TheSUMIF
The SUMIF function
function sums
sums values
values inin one
onerange
rangewhere
where aacondition
condition inin aa
corresponding range
corresponding range isis satisfied.
satisfied. Similarly,
Similarly, the
the AVERAGEIF
AVERAGEIF function
functionaverages
averages
values where a condition is satisfied. Usually, the setup is like the
values where a condition is satisfied. Usually, the setup is like the example to example to the
the
right, where
right, where you
you want
wantto to sum
sum or or average
average scores
scores inin one
onecolumn
column (O),
(O), but
but only
onlyfor
for
rows that
rows thatsatisfy
satisfy aa condition
condition in in another
another column
column (M(M oror N).
N).

To use
To use the
theSUMIF
SUMIF or
or AVERAGEIF
AVERAGEIF functions:
functions:

Enter the
Enter theformula
formula =SUMIF(criterion_range,condition,sum_range).
=SUMIF(criterion_range,condition,sum_range). This This sums
sumsallall
values in
values in sum_range
sum_range where
where the
the corresponding
corresponding value
valuein in criterion_range
criterion_range satisfies
satisfies
thecondition.
the condition.Note
Note that
that the
the criterion_range
criterion_range isis listed
listed first,
first, and
and the
the sum_range
sum_range isis
corresponding range
corresponding range isis satisfied.
satisfied. Similarly,
Similarly, the
the AVERAGEIF
AVERAGEIF function
functionaverages
averages
values where
values where aa condition
condition isis satisfied.
satisfied.Usually,
Usually, the
thesetup
setup isis like
likethe
the example
exampletoto the
the
right, where you want to sum or average scores in one column
right, where you want to sum or average scores in one column (O), but only for (O), but only for
rows that
rows thatsatisfy
satisfy aa condition
condition in in another
another column
column (M (M oror N).
N).

To use
To use the
theSUMIF
SUMIF or
or AVERAGEIF
AVERAGEIF functions:
functions:

Enter the
Enter theformula
formula =SUMIF(criterion_range,condition,sum_range).
=SUMIF(criterion_range,condition,sum_range). This This sums
sumsallall
values in
values in sum_range
sum_range where
where the
the corresponding
corresponding value
valuein in criterion_range
criterion_range satisfies
satisfies
thecondition.
the condition.Note
Note that
that the
the criterion_range
criterion_range isis listed
listed first,
first, and
and the
the sum_range
sum_range isis
listed last. To average instead of sum, enter the similar
listed last. To average instead of sum, enter the similar formula formula
=AVERAGEIF(criterion_range,condition,average_range).
=AVERAGEIF(criterion_range,condition,average_range).
Tryit!
Try it! Calculate
Calculate the
the sums
sums and
and averages
averages in
in the
the red
red cells
cells to
to the
the right
right indicated
indicated by
by
the labels to their left. (Scroll to the right for the answers.)
the labels to their left. (Scroll to the right for the answers.)
Student Gender Age Exam score Gender condition
1 Male 18 62 Age cutoff
2 Female 21 73 Exam score cutoff
3 Female 18 74
4 Female 18 # of "high" scores
5 Male 18 77
6 Female 20 57 Sum of scores for males
7 Female 18 67 Average of scores for males
8 Male 19 90 Sum of scores for "young" people
9 Male 19 77 Average of scores for "young" people
10 Male 22 83 Sum of scores for "old" people
11 Female 20 71 Average of scores for "old" people
12 Female 20 75
13 Female 20 72
14 Female 24 82
15 Female 18 68
16 Male 18 86
17 Female 24 77
18 Male 21 68
19 Male 20 86
20 Female 21
21 Male 20 80
22 Female 18 81
23 Male 20 84
24 Female 19 71
25 Female 18 76
26 Male 21 81
27 Female 18 99
28 Male 20 72
29 Female 18 78
30 Female 21 67
31 Female 21 89
32 Female 19 70
33 Female 19 77
34 Female 18
35 Male 22 83
36 Female 19 74
37 Male 19 87
38 Male 18 75
39 Male 20 86
40 Male 21 77
41 Male 20 73
42 Male 20 74
43 Female 20 79
44 Male 18 80
45 Male 20 77
46 Female 21 72
47 Male 19 77
48 Male 19 71
49 Female 23 70
50 Female 19 68
51 Female 24 79
52 Male 19 75
53 Male 18 80
54 Female 19 73
55 Female 21 61
56 Female 21 62
57 Male 19 68
58 Male 19 92
59 Female 20 85
60 Male 22 77
61 Female 19 79
62 Male 20 86
63 Female 19 83
64 Male 19 83
65 Male 18 76
66 Female 24 89
67 Female 18 72
68 Female 21 69
69 Male 23 66
70 Male 24 71
71 Male 20 80
72 Female 18 61
Male
20
87
# of "high" scores 6

Sum of scores for males 2660


Average of scores for males 78.235
Sum of scores for "young" people 2527
Average of scores for "young" people 76.576
Sum of scores for "old" people 2733
Average of scores for "old" people 75.917
Background on
Background on _IFS
_IFS Functions
Functions

The"plural"
The "plural" functions
functions discussed
discussedhere,
here, COUNTIFS,
COUNTIFS, SUMIFS,
SUMIFS, and
andAVERAGEIFS,
AVERAGEIFS, areare recent
recent
additions in Excel 2007. They allow you to impose multiple conditions, such as
additions in Excel 2007. They allow you to impose multiple conditions, such as male and male and
younger than
younger than the
thevalue
value in
in cell
cell Q4.
Q4.Their
Their arguments,
arguments, described
described in
in more
more detail
detail below,
below, include
include any
any
number of
number of pairs
pairs of
of ranges
ranges and
and criteria,
criteria, such
such as
asL4:L75,"Male".
L4:L75,"Male".

COUNTIFS Functions
COUNTIFS Functions

TheCOUNTIFS
The COUNTIFS function
function counts
countsthe
the number
number of
of rows
rows that
that satisfy
satisfyall
all of
of the
the conditions.
conditions.

To use
To use the
theCOUNTIFS
COUNTIFS function:
function:

Enter the
Enter thefunction
function =COUNTIFS(criterion_range1,condition1,criterion_range2,condition2,...),
=COUNTIFS(criterion_range1,condition1,criterion_range2,condition2,...),
where each
where each criterion_range,condition
criterion_range,condition pair
pair imposes
imposes aa condition
condition on
on aaparticular
particular range
range (usually
(usually aa
column).The
column). The"..."
"..." means
means that
thatany
any number
number of of conditions
conditions can
canbe
be imposed.
imposed.

Tryit!
Try it! In
In the
the blue
blue cell
cell to
to the
the right,
right, find
find the
the number
number of
ofstudents
students with
withthe
the gender
gender above
above itit and
and
ageyounger
age younger than than the
theageagecutoff
cutoff above
above itit who
who scored
scored less
less than
than or
or equal
equal to
tothe
the score
score cutoff
cutoff
aboveit.
above it. (Scroll
(Scroll to
to the
the right
right for
for the
the answer.)
answer.)

SUMIFS and
SUMIFS andAVERAGEIFS
AVERAGEIFSFunctions
Functions

TheSUMIFS
The SUMIFS and and AVERAGEIFS
AVERAGEIFS functions
functionsareare similar
similar inin concept
concepttoto SUMIF
SUMIF andandAVERAGEIF,
AVERAGEIF, butbut
their syntax
their syntax isis different.
different.(Microsoft
(Microsoft evidently
evidentlyliked
liked this
this new
new syntax
syntax better
better than
than the
the original,
original, but
but
they didn't want to change SUMIF and AVERAGEIF syntax because it would
they didn't want to change SUMIF and AVERAGEIF syntax because it would mess up too many mess up too many
existing spreadsheets.)
existing spreadsheets.) Now Now the
the range
range to
to sum
sum oror average
average comes
comes first,
first, and
andthe
thecriteria
criteriaranges
ranges
andconditions
and conditions comecome last.
last.

To use
To use the
theSUMIFS
SUMIFS or
or AVERAGEIFS
AVERAGEIFS function:
function:

Enter the
Enter theformula
formula
=SUMIFS(sum_range,criterion_range1,condition1,criterion_range2,condition2,...)
=SUMIFS(sum_range,criterion_range1,condition1,criterion_range2,condition2,...)
or =AVERAGEIFS(average_range,criterion_range1,condition1,criterion_range2,condition2,...)
or =AVERAGEIFS(average_range,criterion_range1,condition1,criterion_range2,condition2,...)

Again, the
Again, the setup
setup isis typically
typicallylike
like the
the example
example to tothe
the right.
right.There
There isis aa column
column such
suchas
as exam
examscore
score
to sum
to sumor or average.
average. The Thecriteria
criteria impose
imposeconditions
conditions on
onother
other columns
columns (or (or even
even the
the same
same
column).Only
column). Only those
thoserows rows that
that meet
meet all
all of
of the
theconditions
conditions are
arepart
part of of the
thesum
sum or
or average.
average.

Tryit!
Try it! In
In the
the red
red cells
cells to
to the
theright,
right, calculate
calculatethe
the sum
sumand
andaverage
averageofof all
all scores
scores made
made by by the
the
gender above
gender above themthem and
and ages
ages younger
younger than
than the
the age
age cutoff
cutoff above
above them.
them. (Scroll
(Scroll to
to the
the right
right for
for
the answers.)
the answers.)
Note: According
Note: According to to Excel's
Excel's online
online help,
help, when
whenusing
using these
these functions,
functions, ifif aacell
cell in
in aacriterion
criterion range
range
isis blank,
blank, itit isis treated
treated asas0.
0. However,
However, thisthis doesn't
doesn't appear
appear toto be
betrue.
true.For
For example,
example, the thesecond
second
student does
student does not notcurrently
currentlysatisfy
satisfy the
the conditions
conditions (too
(too old).
old). Change
Change her
her age
ageto to 0,
0, and
andyou
youwill
will
see that
see thatthe
the answers
answers change.
change.Then
Then delete
delete her
her age
age (make
(make itit blank),
blank), and
and thetheanswers
answers willwill revert
revert
back to
back to their
their original
originalvalues.
values.
gender above
gender above them
them and
and ages
ages younger
younger than
than the
the age
age cutoff
cutoff above
above them.
them. (Scroll
(Scroll to
to the
the right
right for
for
theanswers.)
the answers.)

Note: According
Note: According to to Excel's
Excel's online
online help,
help, when
whenusing
using these
these functions,
functions, ifif aacell
cell in
in aacriterion
criterion range
range
isis blank,
blank, itit isis treated
treated asas0.
0. However,
However, thisthis doesn't
doesn't appear
appear toto be
betrue.
true.For
For example,
example, the thesecond
second
student does
student does not notcurrently
currentlysatisfy
satisfy the
the conditions
conditions (too
(too old).
old). Change
Change her
her ageageto to 0,
0, and
andyou
youwill
will
see that the answers change. Then delete her age (make it blank), and
see that the answers change. Then delete her age (make it blank), and the answers will revert the answers will revert
back to
back to their
their original
originalvalues.
values.
Student Gender Age Exam score Gender condition Female
1 Male 18 62 Age cutoff 20
tt
nd 2 Female 21 73 Exam score cutoff 87
nd
clude any
clude any 3 Female 18 1
4 Female 18 65 COUNTIFS question
5 Male 18 77
6 Female 20 57 SUMIFS question
7 Female 18 67 AVERAGEIFS question
8 Male 19 90
9 Male 19 77
10 Male 22 83
11 Female 20 71
12 Female 20 75
13 Female 20 72
on2,...),
n2,...),
usually aa
usually 14 Female 24 82
15 Female 18 68
16 Male 18 86
itit and
and
utoff
toff 17 Female 24 77
18 Male 21 68
19 Male 20 86
20 Female 21 89
21 Male 20 80
22 Female 18 81
23 Male 20 84
24 Female 19 71
F,F, but
but
25 Female 18 76
inal,
nal, butbut
oo many
o many 26 Male 21 81
ranges
anges 27 Female 18 99
28 Male 20 72
29 Female 18 78
30 Female 21 67
31 Female 21 89
ition2,...)
tion2,...) 32 Female 19 70
amscore
score 33 Female 19 77
am
e 34 Female 18 79
ge.
e. 35 Male 22 83
the 36 Female 19 74
the
ght for
ght for 37 Male 19 87
38 Male 18 75
on range
on range 39 Male 20 86
econd
cond 40 Male 21 77
ouwill
ou will
lll revert
revert
ght for
ght for

on range
on range
econd
cond
ouwill
ou will
lll revert
revert 41 Male 20 73
42 Male 20 74
43 Female 20 79
44 Male 18 80
45 Male 20 77
46 Female 21 72
47 Male 19 77
48 Male 19 71
49 Female 23 70
50 Female 19 68
51 Female 24 79
52 Male 19 75
53 Male 18 80
54 Female 19 73
55 Female 21 61
56 Female 21 62
57 Male 19 68
58 Male 19 92
59 Female 20 85
60 Male 22 77
61 Female 19 79
62 Male 20 86
63 Female 19 83
64 Male 19 83
65 Male 18 76
66 Female 24 89
67 Female 18 72
68 Female 21 69
69 Male 23 66
70 Male 24 71
71 Male 20 80
72 Female 18 61
COUNTIFS question

SUMIFS question
AVERAGEIFS question
18

1342
70.632
SUMPRODUCT Function
SUMPRODUCT Function

There are
There are many
many times
times when
whenyou
youneed
needtoto sum
sumproducts
products ofof values
valuesinin two
two (or
(or
possibly more than two) same-size ranges. Fortunately, there is a SUMPRODUCT
possibly more than two) same-size ranges. Fortunately, there is a SUMPRODUCT
function that
function that sums
sums products
productsquickly.
quickly.

To use
To use the
theSUMPRODUCT
SUMPRODUCT function:
function:

Enter the
Enter theformula
formula =SUMPRODUCT(range1,range2),
=SUMPRODUCT(range1,range2), where where range1
range1 and
and range2
range2
areexactly
are exactly the
thesame
samesize.
size. For
For example,
example, they
theymight
might be
be two
twocolumn
column ranges
rangeswith
with 10
10
cells each,
cells each, or
or they
theymight
mightbe
be two
two ranges
ranges with
with44 rows
rows and
and 10
10 columns
columns each.
each.The
The
formulasums
formula sums thethe products
products ofof the
the corresponding
corresponding values
values from
from the
the two
two ranges.
ranges.

There can
There can actually
actuallybe
be more
more than
than two
two ranges
ranges in
in the
the SUMPRODUCT
SUMPRODUCT formula,
formula,
separated by
separated by commas,
commas, as
aslong
long as
as all
all of
of them
them have
have exactly
exactly the
the same
same size.
size. This
This isis
not as common as having only two ranges, but it is sometimes
not as common as having only two ranges, but it is sometimes useful. useful.

Tryit!
Try it! Sum
Sumthe
theproducts
productsofof the
thetwo
two ranges
rangesin inthe
the example
example to to the
the right
right to
to find
findthe
the
total shipping
total shippingcost.
cost.Enter
Enter the
theresult
result in
in the
the blue
bluecell
cell to
to the
the right.
right. (The
(The answer
answer
should be
should be$1,609.50.)
$1,609.50.)

Bythe
By the way,
way, ifif you
you are
are tempted
temptedto to write
writethe
theformula
formula without
without the
the SUMPRODUCT
SUMPRODUCT
function as
function asthe
the sum sum of
of nine
nine products,
products, asas many
many beginning
beginning users
users tend
tend to
to do,
do,
imagine how long your formula would be if there were 10 plants
imagine how long your formula would be if there were 10 plants and 50 cities!and 50 cities!
TheSUMPRODUCT
The SUMPRODUCT function functionisisextremely
extremely efficient,
efficient, so
so get
get used
used to
to using
using it.
it.
Unit shipping costs City1 City2 City3
Plant1 1.25 1.35 1.55
Plant2 1.15 1.45 1.25
Plant3 1.35 1.45 1.15

Units shipped City1 City2 City3


Plant1 155 180 0
Plant2 250 130 185
Plant3 0 210 140

Total cost
General Information
General Information about
about Math
Math Functions
Functions

There are
There are aanumber
number of of math
math functions
functionsyou
you might
might find
find useful.
useful.AA few
fewofof the
themost
most
common ones are listed here. For other math functions, browse
common ones are listed here. For other math functions, browse the Math and the Math and
Trig category
Trig category ononthe
the Formulas
Formulas ribbon.
ribbon.You
Youcan
can find
find even
even more
more technical
technical functions
functions
under More
under MoreFunctions
Functions inin the
the Engineering
Engineering group.
group.
INT (Integer)
INT (Integer) Function
Function

The INT
The INT function
function takes
takes aadecimal
decimal value
value and
and returns
returns an
an integer
integer by
by "chopping
"chopping off"
off"
(truncating) the decimal. More exactly, it returns the integer just to the left
(truncating) the decimal. More exactly, it returns the integer just to the left of the of the
given decimal
given decimal number
number on on the
the number
number line.
line. ItItdoes
does not
not round
round to
to the
the nearest
nearestinteger.
integer.
To use
To use it:
it:

Enter the
Enter the formula
formula =INT(value),
=INT(value), where
where value
value isis aanumber
number or
or aareference
reference to
toaa
numerical cell.
numerical cell.

Try it!
Try it! In
Inthe
theblue
blue range
range to
tothe
the right,
right, apply
apply the
theINT
INT function
function to
to the
the numbers
numbersabove.
above.

ROUND Function
ROUND Function

TheROUND
The ROUND function
functionrounds
rounds aa value
valueto
to the
the number
number of
of decimals
decimalsyou
you specify.
specify.To
To use
use
it:
it:
Enter the
Enter theformula
formula =ROUND(value,decimals),
=ROUND(value,decimals), where where value
value isisaa number
number or or aa reference
reference
to a numerical cell, and decimals indicates the number of decimal
to a numerical cell, and decimals indicates the number of decimal places to round places to round
to.IfIf decimals
to. decimals isis 0,
0, itit rounds
rounds to
to the
the nearest
nearest integer.
integer. IfIf decimals
decimals isis positive,
positive, itit rounds
rounds
to this
to this many
manydecimals.
decimals. IfIf decimals
decimals isis negative,
negative, ititrounds
rounds to to the
the nearest
nearestten
ten(decimals
(decimals
== -1),
-1), the
the nearest
nearest hundred
hundred (decimals
(decimals ==-2),
-2), the
the nearest
nearest thousand
thousand(decimals
(decimals ==-3), -3), and
and
so on.
so on.
Tryit!
Try it! In
In the
the red
red range
range to
tothe
the right,
right, apply
apply the
theROUND
ROUND function
function to
to the
thenumbers
numbers two
two
rows above,
rows above, using
using the
the decimals
decimals values
values in
in the
the row
row above.
above.
1.7 -3.2 14 -7

100.35 14325 16.3467 154432 0.3569


0 -2 2 -3 1
ABS (Absolute
ABS (Absolute Value)
Value) Function
Function

The ABS
The ABS function
functionreturns
returns the
theabsolute
absolutevalue
value of
of aa number.
number. To
To use
use it:
it:

Enter the
Enter the formula
formula =ABS(value),
=ABS(value), where
where value
value isis aa number
number or
or aa reference
reference to
to aa
numerical cell.
numerical cell.

Try it!
Try it! In
Inthe
theblue
blue range
range to
tothe
the right,
right, apply
apply the
theABS
ABS function
function to
tothe
the numbers
numbers in
in the
the
row above.
row above.

SQRT (Square
SQRT (Square Root)
Root) Function
Function

The SQRT
The SQRT function
function returns
returns the
the square
square root
root of
of aa number.
number. To
Touse
use it:
it:
Enter the
Enter the formula
formula =SQRT(value),
=SQRT(value), where
where value
value isis aanumber
number or
or aa reference
reference to
to aa
numerical cell. If value is negative, this returns an
numerical cell. If value is negative, this returns an error.error.

Try it!
Try it! In
Inthe
thered
red range
range to
to the
theright,
right, apply
apply the
the SQRT
SQRT function
functionto
to the
the numbers
numbers in
in the
the
row above.
row above.

SUMSQ (Sum
SUMSQ (Sum of
ofSquares)
Squares) Function
Function

The SUMSQ
The SUMSQfunction
functionreturns
returns the
the sum
sumof
of squares
squares of
of numbers.
numbers.To
To use
useit:
it:

Enter the
Enter the formula
formula =SUMSQ(range),
=SUMSQ(range), where
where range
range isis any
any range
range of
of numbers.
numbers.

Try it!
Try it! In
Inthe
thegreen
green cell
cell to
tothe
the right,
right, calculate
calculate the
the sum
sumof
of squares
squares of
of the
the numbers
numbers
to its left.
to its left.
6 -50 0

64 0.5 -20 0

21 43 4 21 35
LN (Natural
LN (Natural Logarithm)
Logarithm) Function
Function

TheLN
The LN function
function returns
returnsthe
the natural
naturallogarithm
logarithm of
of aa number.
number. To
Touse
use it:
it:

Enter the
Enter theformula
formula =LN(value),
=LN(value), where
where value
value isis aanumber
number or
or aareference
reference to
toaa numerical
numerical
cell. IfIf value
cell. value isiszero
zero or
or negative,
negative, this
this returns
returns anan error.
error.

Tryit!
Try it! In
In the
the blue
blue range
range to
to the
the right,
right, apply
applythe
the LN
LN function
functionto
to the
the numbers
numbersin
inthe
the row
row
above.
above.
There isis also
There also aaLOG10
LOG10 function,
function, which
which returns
returns the
thelog
log to
to the
the base
base 10
10that
thatyou
youmight
might
have learned in high school. There is also a LOG function, where you can
have learned in high school. There is also a LOG function, where you can supply the supply the
base. But
base. ButLN LNtends
tends to
to be
be used
used in
inmost
most real
real applications.
applications.

EXP (Exponential)
EXP (Exponential) Function
Function

The EXP
The EXPfunction
function returns
returns the
the exponential
exponential function
function of
of aanumber.
number.That That is,
is,ififyou
youapply
apply
EXPto
EXP to some
somenumber
number x,x, the
the result
result isis the
thespecial
special number
number eeraised
raised to
tothe
thepower
power x,x,
whereee isis approximately
where approximately2.718.
2.718. In
In math
math books,
books, you
you see
see this
this written
writtenasas eexx..

ItItturns
turns out
outthat
thatEXP
EXP and
and LN
LN are are"inverses"
"inverses" of
of one
one another.
another. IfIf you
you start
start with
with aa
number xx and
number and take
take EXP
EXPof
of it,
it, and
and then
thentake
takeLNLNof
of the
theresult,
result, you
you end
endup up with
withx.x.
Alternatively, ifif you
Alternatively, youstart
startwith
with aa(positive)
(positive) number
number xxandandtake
takeLN LNof
of it,
it, and
and then
thentake
take
EXP of the result, you end up
EXP of the result, you end up with x. with x.

To use
To use the
the EXP
EXP function:
function:

Enter the
Enter the formula
formula =EXP(value),
=EXP(value), where
where value
value isis aa number
number or
or aa reference
reference to
to aa
numerical cell.
numerical cell.

Try it!
Try it! In
Inthe
thered
red range
range to
to the
theright,
right, apply
apply thethe EXP
EXPfunction
function to to the
the numbers
numbersininthe
the
row above. Then in the green range, apply the LN function to
row above. Then in the green range, apply the LN function to the numbers in the the numbers in the
red range.
red range. Note
Note that
that the
the value
valueyouyouget
get in
in the
thefirst
firstred
red cell
cell isis the
the special
special number
number e.e.
1023 0.7 1 0 -40

1 -4 2.3 0 15
RAND(Random)
RAND (Random) Function
Function

TheRAND
The RANDfunction
function returns
returnsaa random
random number
number uniformly
uniformly distributed
distributed between
between 00
and 1. That is, the random number is just as likely to be near any
and 1. That is, the random number is just as likely to be near any number number
between from
between from00 toto 11as
as to
to any
anyother
other number
number between
between 00and
and 1.1. To
To use
use it:
it:

Enter the
Enter theformula
formula=RAND().
=RAND(). This
This isis aa function
function with
with no
no arguments
arguments(nothing
(nothing inside
inside
the parentheses), but the parentheses must be included.
the parentheses), but the parentheses must be included.
Youcan
You can enter
enter this
this formula
formula in
in as
as many
many cells
cells as
as you
you like,
like, and
andeacheach will
will have
have aa
differentrandom
different randomnumber.
number.Also,
Also, these
thesenumbers
numbers areare "live."
"live." IfIf you
you press
press the
therecalc
recalc
(F9) key, they will all change.
(F9) key, they will all change.
Tryit!
Try it! Enter
Enter the
theRAND
RANDfunction
function in
in any
any cell
cell to
to the
theright
right and
and copy
copy itit to
to some
some range.
range.
Then press
Then press the
the F9
F9 key
key aafew
few times
times and
andwatch
watch the therandom
randomnumbers
numbers change.
change.

RANDBETWEEN (Random
RANDBETWEEN (Random Between)
Between) Function
Function

Until Excel
Until Excel 2007,
2007, the
the RAND
RAND function
function was
was thethe only
only function
functionfor
for generating
generatingrandom
random
numbers. Fortunately, another very useful function, RANDBETWEEN,
numbers. Fortunately, another very useful function, RANDBETWEEN, was added was added
in Excel
in Excel 2007.
2007. ItIttakes
takestwo
two integer
integer arguments
arguments and and generates
generates aarandom
randominteger
integer
between these
between these two
two values
values (inclusive)
(inclusive) so
so that
that all
all of
ofthe
thepossibilities
possibilities are
are equally
equally
likely.To
likely. To use
useit:
it:

Enter the
Enter theformula
formula =RANDBETWEEN(min,max),
=RANDBETWEEN(min,max), where
where min
min and
and max
max are
are two
two
integers (with
integers (with min
min less
less than
than max).
max).

Tryit!
Try it! Generate
Generate random
randomrolls
rollsof
of aadie
die (1
(1 to
to6)
6) in
inseveral
several cells
cells to
to the
the right.
right.Then
Then
pressthe
press the F9
F9 key
key to
tosee
see how
how they
they change
changerandomly.
randomly.
General Information
General Information About
About Text
Text Manipulation
Manipulation and
andText
Text Functions
Functions

Most people
Most people useuseExcel
Excelfunctions
functions toto calculate
calculate numbers.
numbers. However,
However, Excel
Excel also
also
provides several very useful functions for manipulating text. These
provides several very useful functions for manipulating text. These can be can be real
real
time-savers. IfIf you
time-savers. you have
have ever
ever been
been required
requiredtoto manipulate
manipulateaa listlist of
of hundreds
hundreds of of
names or
names or any
anysimilar
similar mind-numbing
mind-numbing task,task, you
you will
will definitely
definitely appreciate
appreciate these
these
functions.In
functions. In fact,
fact, you
you will
will wish
wishyou
you knew
knewabout
about these
thesefunctions
functions earlier!
earlier! This
This
section illustrates some of the most common ways to manipulate
section illustrates some of the most common ways to manipulate text in Excel. text in Excel.

Thenext
The next worksheet
worksheet describes
describes two two handy
handy text
text functions,
functions, TRIM
TRIM and andVALUE.
VALUE.Then
Then
thelast
the last three
threeworksheets
worksheets in in this
thissection
sectiondiscuss
discuss two
two common
common text text tasks,
tasks,
concatenating and
concatenating andparsing.
parsing. These
These areare opposites.
opposites.Concatenating
Concatenating means
means to to put
put
several pieces
several pieces together,
together, such
suchas as forming
forming the
thename
name"John
"John Smith"
Smith" fromfrom the
thetwo
two
pieces "John"
pieces "John" and
and "Smith".
"Smith".Parsing
Parsingmeans
means toto separate
separate text
text into
into several
several pieces,
pieces,
suchas
such as starting
startingwith
with the
the text
text"Smith,
"Smith, John"
John" and
and separating
separatingitit into
into the
thefirst
firstname
name
"John" and the last name "Smith". As you will see, concatenating
"John" and the last name "Smith". As you will see, concatenating is relatively is relatively
easy, whereas
easy, whereas parsing
parsing isis typically
typicallymore
more difficult.
difficult.
TRIM Function
TRIM Function

Text in
Text in aa cell
cellsometimes
sometimes hashas leading
leading or
or trailing
trailing spaces.
spaces. For
For example,
example, youyoucan can
guess from the alignment that the names to the right all
guess from the alignment that the names to the right all have some leadinghave some leading
spaces. (They
spaces. (They also
also have
havesome
some trailing
trailing spaces,
spaces, although
althoughthisthis isis not
not obvious.)
obvious.) This
This isis
not necessarily
not necessarilyaa problem,
problem, butbut sometimes
sometimes you youwould
would like
like to
to delete
delete any
any leading
leading or
or
trailing spaces.
trailing spaces.Doing
Doing this
this manually
manuallycould could take
take hours,
hours, so
so luckily
luckilythere
thereisis aa
function, TRIM,
function, TRIM, that
that does
does itit automatically.
automatically.

To use
To use the
theTRIM
TRIM function:
function:

Enter the
Enter theformula
formula =TRIM(cell),
=TRIM(cell), where
where cell
cell isis aareference
reference to
tothe
the cell
cell to
to be
betrimmed.
trimmed.

Tryit!
Try it! In
In column
column L,L, apply
applythe
theTRIMTRIM function
function toto the
the names
names inin column
column K.K. Then
Then copy
copy
theformulas
the formulasin incolumn
column LLand
and paste
paste them
them over
over themselves
themselves asas values.
values.Now
Nowthere
there isis
no dependence
no dependenceon on the
thenames
names in in column
columnK, K, so
somove
move the
thevalues
values in incolumn
column LL to
to
columnK,
column K, replacing
replacingthe
theoriginals.
originals.(This
(This should
should take
take about
about five
fiveseconds,
seconds, and
and itit
wouldn't take
wouldn't take much
muchlonger
longer ifif you
you started
started with
with thousands
thousands ofof names.
names.That's
That's
efficiency!)
efficiency!)

VALUE Function
VALUE Function

Have you
Have you ever
ever gotten
gottenaa spreadsheet
spreadsheet with withaa lot
lot of
of numbers,
numbers, but butthethe numbers
numbers areare
lef justified in their cells, like those to the right? They are probably
lef justified in their cells, like those to the right? They are probably the result of the result of
dumpingdata
dumping data from
from aa legacy
legacysystem
systeminto
into Excel,
Excel, with
withthe
theresult
result that
that the
the numbers
numbers
arereally
are really text
text that
that only
onlylook
look like
likenumbers.
numbers. TheThetipoff
tipoff isisthat
thatthey
they are
are left
leftjustified;
justified;
numbers are
numbers arealmost
almost always
always right
right justified.
justified.
Trydoing
Try doing arithmetic
arithmetic onon the
thenumbers
numbersto to the
theright,
right, such
suchas as summing
summing them.
them. ItItwon't
won't
work because
work becauseExcel
Excel interprets
interprets them
themasas text,
text, and
and itit can't
can't do
do arithmetic
arithmetic on
ontext.
text.
Andunfortunately,
And unfortunately, ititdoes
does no
no good
good to
to simply
simply right
rightjustify
justify them;
them; they
they are
are still
still text.
text.
Luckily, there is a very useful function, VALUE, that takes text that looks
Luckily, there is a very useful function, VALUE, that takes text that looks like a like a
number and
number andmakes
makes itit aanumber.
number.

To use
To use the
theVALUE
VALUEfunction:
function:

Enter the
Enter theformula
formula =VALUE(cell),
=VALUE(cell), where
where cell
cell isis aa reference
referenceto
to the
the cell
cell that
that contains
contains
thetext.
the text.

Tryit!
Try it! Use
Usethe
theVALUE
VALUEfunction
function in
in column
columnLL to
to transform
transformthe
thetext
text in
in column
column KK to
to
numbers.Then
numbers. Then check
check that
thatyou
youcan
can do
do arithmetic
arithmetic onon the
thevalues
values in
in column
column L.L.
Bob
Jane
Justin
Lindsay
George
Sam
Christine
Tom
Jenny
Doug

19
65
36
12
57
93
45
Concatenating
Concatenating
To concatenate,
To concatenate, you
you start
startwith
with two
two or
or more
more pieces
pieces of
of text
text and
andstring
stringthem
them
together. For example, you might concatenate Bob and Jones
together. For example, you might concatenate Bob and Jones into Bob into Bob
Jones. There
Jones. There are
aretwo
two equivalent
equivalent ways
ways to
to concatenate:
concatenate: with
with the
theampersand
ampersand (&)
(&)
symbol and
symbol and with
with the
the CONCATENATE
CONCATENATEfunction.
function. Both
Both are
are described
described here.
here.

To concatenate
To concatenatethe thetext
text in
in cells
cells A1
A1and
and B1
B1with
withthethe ampersand
ampersandsymbol,
symbol, enter
enter the
the
formula =A1&B1
formula =A1&B1 in in cell
cell C1.
C1.Literal
Literal text
textcan
can also
also be
beincluded,
included, such
such as
as =A1&,
=A1&,
&B1. In
&B1. In this
thiscase,
case, ififA1
A1 contains
contains Jones
Jones and
and B1B1contains
contains Bob,
Bob, then
then C1
C1will
will
containJones,
contain Jones, Bob.
Bob.ThisThis concatenates
concatenates thethelast
last name,
name, aa literal
literal comma
comma andand space,
space,
and the first name. In general, separate the pieces with ampersands,
and the first name. In general, separate the pieces with ampersands, and and
surround literal
surround literal text
text with
withdouble
double quotes.
quotes.

To concatenate
To concatenatethe thetext
text in
in cells
cells A1
A1and
and B1
B1with
withthe
the CONCATENATE
CONCATENATEfunction,
function, enter
enter
the formula =CONCATENATE(A1,, ,B1). In words, you enter
the formula =CONCATENATE(A1,, ,B1). In words, you enter the pieces you the pieces you
want to
want to concatenate,
concatenate, separated
separated by by commas.
commas.These
These pieces
pieces can
can be
becell
cell references
references
or literal
or literal text.
text. In
Inthe
the latter
latter case,
case, they
they should
should be
be surrounded
surrounded with
withdouble
double quotes.
quotes.

Tryit!
Try it! Concatenate
Concatenate thethe first
first names,
names, middle
middle initials,
initials, and
and last
last names
names inin columns
columns K,K,
L,L, and
and M Mso
sothat
thatfull
full names
names of of the
the form
form Jones,
Jones, BobBob E. E. appear
appear inin column
columnN. N. Do
Do this
this
with the
with the ampersand
ampersandsymbolsymbol andand then
then dodo itit again
again with
withthe theCONCATENATE
CONCATENATE
function.
function.
Bob E Jones
Stephen C Davis
Andy T Thompson
John F Wilson
Kathy C Fredericks
Karen D Williams
Tom T Smith
Peter F Jennings
Ted R Benson
Jason E Samson
Parsing with
Parsing withText
Text to
to Columns
Columns

Parsingtext,
Parsing text, that
that is,
is, separating
separating itit into
intoits
its pieces,
pieces, isis sometimes
sometimes easy,easy, and
and itit isis
sometimes difficult. The text functions illustrated on
sometimes difficult. The text functions illustrated on the next sheet arethe next sheet areforfor the
the
difficultcases,
difficult cases, but
but there
there isis an
an easy
easy tool
tool worth
worthtrying
tryingfirst.
first.Suppose
Suppose youyou import
import
datafrom
data from aa legacy
legacy system
system or or aa Web
Web site,
site, and
andeverything
everythinggets gets imported
importedto to aa single
single
column, such
column, such asas in
in column
columnKK to to the
the right.
right. The
The pattern
patternisis pretty
pretty clear:
clear: each
each cellcell
contains five
contains five numbers,
numbers, all all separated
separatedby bycommas.
commas. To Toparse
parse these
these into
intofive
five columns
columns
with one
with one number
number per per cell,
cell, you
you can
can use
usethethe Text
Text to
to Columns
Columns button
button onon the
the DataData
ribbon. This
ribbon. Thislaunches
launches aafairly
fairly simple
simplewizard
wizard (basically,
(basically, thethesame
samewizard
wizard used
usedfor for
importing aatext
importing text file),
file), where
whereyou youcancanindicate
indicate that
that thethe "delimiter"
"delimiter" isis aacomma.
comma.

Tryit!
Try it! Select
Selectthe
the data
datainin column
columnKK and andtry
try the
the Text
Textto
to Columns
Columns wizard.
wizard.Note
Note that
thatitit
places the
places theresults
resultsin
incolumns
columns K-O,
K-O, replacing
replacing the
the original
original data
datainincolumn
column K.K.IfIf you
you
want to
want to keep
keep the
theoriginal
original data
data for
for some
somereason,
reason, just
justmake
make aacopy
copy in
in column
column LL andand
then parse the
then parse the copy.copy.
606,360,516,1757,371
1631,1337,1260,1855,2823
904,749,486,1852,1612
2463,1324,1889,2597,312
1256,1839,1745,244,1508
2159,2917,1699,1351,974
1084,2379,1791,1933,507
1686,2454,1954,256,1068
1274,2330,2334,343,255
303,2128,578,824,1714
2989,2317,2196,642,2812
1743,2122,2428,871,2701
2817,2330,1217,407,327
894,1893,1963,1641,2533
2747,1952,243,2832,1487
358,2674,1660,1006,1249
1032,939,2172,2112,347
2639,2489,2905,412,2877
730,696,639,454,1591
1774,2506,2690,2498,2407
2406,493,1457,1317,2993
1359,894,2281,2454,1239
2847,1432,381,1518,941
1597,313,1231,596,702
2838,2547,846,868,1753
2049,558,201,1034,351
1395,1314,1004,489,275
2628,2596,1901,2114,381
1439,1574,2318,277,1202
918,2177,621,1777,2106
867,2906,2844,2173,1370
2314,236,1387,1586,1106
1316,1475,1791,1494,2405
1006,795,1804,861,979
General Approach
General Approach to
to Parsing
Parsing with
with Text
Text Functions
Functions

Suppose, for
Suppose, for example,
example, that that someone
someone has has given
given you
you aa spreadsheet
spreadsheet withwith aa data
data set
set such
such as
as the
theone
one to
to
the right. Each cell in column K has a persons name: last name, then a comma
the right. Each cell in column K has a persons name: last name, then a comma and a space, and then and a space, and then
first name.
first name. Your
Your job
job isis to
to parse
parse (that
(that is,
is, separate)
separate) these
thesenames
names as as indicated
indicated for
for the
the name
name inin cells
cells L3
L3
and M3.
and M3. That
Thatis,
is, column
column LL should
shouldhave
haveall all of
of the
the first
first names
names and
and column
columnM M should
should have
have all
allof
of the
thelast
last
names. IfIf this
names. thissounds
sounds easy, easy, imagine
imagine thatthatthere
thereare are10,000
10,000names
names in in column
column K.K.What
What would
wouldyouyoudo?do? IfIf
you just
you just start
starttyping,
typing, youyouwillwill be
be at
at for
for aa long
long time,
time, and
and you
you will
will undoubtedly
undoubtedly make makemistakes
mistakes along
along the
the
way!
way!
Fortunately, there
Fortunately, there isis aa much
much better
better way.
way.The
Thekey
key isis to
to look
lookfor
for patterns.
patterns. In
Inthis
this example,
example, notenote that
that
every name has a comma and a space. The first name comes after the
every name has a comma and a space. The first name comes after the comma and space, and thecomma and space, and thelast
last
name comes
name comes before
beforeit. it. For
For the
the name
name"Jones,
"Jones, Bob",
Bob", there
there areare 10
10characters,
characters, including
including the
the comma
comma and and
space, and
space, and the
thecomma
comma and andspace
space are
are characters
characters 66andand7. 7. So
So the
thefirst
firstname
nameisisthethe rightmost
rightmost 33
characters and
characters and the
thelast
lastnamenameisisthe
the leftmost
leftmost 55characters.
characters. In In any
anyparsing
parsing operation,
operation, this
this isis the
the first
firstand
and
the most crucial step: discover the
the most crucial step: discover the pattern. pattern.

Once you
Once you discover
discover the
the pattern,
pattern, you
you can
can then
then exploit
exploit itit with
with aa number
number of
of useful
useful text
textfunctions.
functions. The
The
ones discussed
ones discussed here
here are
areFIND,
FIND, LEN,
LEN, RIGHT,
RIGHT, LEFT,
LEFT, and
and MID.
MID.(If(If you
you want
wanttoto learn
learn about
about other
other text
text
functions, click
functions, clickthe
theText
Text dropdown
dropdown list
list on
onthe
the Formulas
Formulas ribbon.)
ribbon.)

LEN (Length)
LEN (Length) Function
Function

The LEN
The LEN function
functionreturns
returns the
thenumber
number of
of characters
characters in
in aa piece
piece of
of text.
text.

To use
To use the
the LEN
LEN function:
function:

Enter the
Enter the formula
formula =LEN(text)
=LEN(text)
For example,
For example, =LEN("Bobby
=LEN("Bobby Jones")
Jones") returns
returns11.
11. (It
(Itincludes
includesthe
the space.)
space.)

LEFT, RIGHT,
LEFT, RIGHT, MID
MID Functions
Functions

These functions
These functions return
return the
theleft,
left, right,
right, or
or middle
middle characters
characters from
from aa piece
piece of
of text,
text, where
where you
you can
can
indicate how many characters to
indicate how many characters to return. return.

To use
To use the
the RIGHT
RIGHT function:
function:

Enter the
Enter the formula
formula =RIGHT(text,
=RIGHT(text, n), n), where
where nn isis an
an integer.
integer. This
This returns
returns the
theright
right nn characters
characters in
in text.
text. (If
(If
nn isis greater
greater than
than LEN(text),
LEN(text), itit returns
returns the
the entire
entire text.)
text.)
To use
To use the
the LEFT
LEFT function:
function:

Enter the
Enter the formula
formula =LEFT(text,
=LEFT(text, n), n), where
where nn isis an
an integer.
integer. This
Thisreturns
returns the
theleft
left nn characters
characters in
in text.
text. (If
(If nn isis
greater than
greater thanLEN(text),
LEN(text), ititreturns
returns the
theentire
entire text.)
text.)

To use
To use the
the MID
MID function:
function:
Enter the
Enter the formula
formula =RIGHT(text,
=RIGHT(text, n),n), where
where nn isis an
an integer.
integer. This
This returns
returns the
theright
right nn characters
characters in
in text.
text. (If
(If
n is greater than LEN(text), it returns the entire
n is greater than LEN(text), it returns the entire text.)text.)

To use
To use the
the LEFT
LEFT function:
function:

Enter the
Enter the formula
formula =LEFT(text,
=LEFT(text, n), n), where
where nn isis an
an integer.
integer. This
Thisreturns
returns the
theleft
left nn characters
characters in
in text.
text. (If
(If nn isis
greater than
greater thanLEN(text),
LEN(text), ititreturns
returns the
theentire
entire text.)
text.)

To use
To use the
the MID
MID function:
function:

Enter the
Enter the formula
formula =MID(text,s,n),
=MID(text,s,n), where
where ssisisan
an integer
integer and
and nn isis an
an optional
optional integer.
integer. IfIf nn isismissing,
missing, this
this
returnsall
returns all of
of text
textfrom
from character
character sson.
on. (s
(s stands
stands for
for start.)
start.) Otherwise,
Otherwise, itit returns
returns nn characters
characters of of text,
text,
starting with
starting with character
character s.s.

Hereare
Here are some
some examples
examples of
of MID:
MID:

The function
The function =MID(Freddie,5)
=MID(Freddie,5) returns
returns die.
die.
The function =MID(Freddie,5,2) returns di.
The function =MID(Freddie,5,2) returns di.
The function
The function =MID(Jones,
=MID(Jones, Bob,FIND(,,Jones,
Bob,FIND(,,Jones, Bob)+2,1)
Bob)+2,1) returns
returns B.
B. (Read
(Read the
thenext
next text
text box
boxto
to see
see
how this
how thisworks.)
works.)

FIND Function
FIND Function

The FIND
The FIND function
functionreturns
returns thethe position
position of
of the
thefirst
firstoccurrence
occurrence of
of aa string
stringof
of characters
characters (which
(which could
could be
be
aasingle
single character)
character) in
in aa piece
pieceof
of text.
text.

To use
To use the
the FIND
FIND function:
function:

The FIND
The FIND function
functionhas has the
the syntax
syntax =FIND(subtext,text,n),
=FIND(subtext,text,n), where where subtext
subtext isisaa piece
piece of
of text
text to
to be
be found
found
in text,
in text, text
text isis the
the original
original text,
text, and
and nn isisan
an optional
optional integer
integer argument.
argument. This
Thisfunction
function returns
returns thethe
position of
position of the
the first
first occurrence
occurrenceof of subtext,
subtext, ifif any.
any.IfIf there
thereare
are no
no occurrences,
occurrences, itit returns
returns an
an error.
error. IfIf the
the
argument nn isis missing,
argument missing, the
the search
searchstarts
starts at
atcharacter
character 1; 1; otherwise,
otherwise, the
thesearch
search starts
startsat
at character
character n. n.

Hereare
Here are aafew
few examples:
examples:

The formula
The formula =FIND(,,Jones,
=FIND(,,Jones, Bob)
Bob) returns
returns 6,
6, because
becausethe
the comma
commaisis the
the6th
6th character
character in
in Jones,
Jones, Bob.
Bob.

The formula
The formula =FIND(nes,Jones,
=FIND(nes,Jones, Bob)
Bob) returns
returns 3,
3, because
becausethe
the subtext
subtext nes
nes begins
begins in
in the
the 3rd
3rd
character of Jones, Bob.
character of Jones, Bob.
The formula
The formula =FIND(o,Jones,
=FIND(o,Jones, Bob)
Bob) returns
returns 2,
2, because
because thethe first
first occurrence
occurrence ofof the
the letter
letter o
ooccurs
occurs in
in
the2nd
the 2ndcharacter
character of
of Jones,
Jones, Bob.
Bob. However,
However, the
theformula
formula=FIND(o,
=FIND(o, Jones,
Jones, Bob,3)
Bob,3) returns
returns 9,9, because
because
thefirst
the firstoccurrence
occurrence ofof o
o starting
startingfrom
from character
character 33 isis character
character 9. 9.

The formula
The formula =FIND(t,Jones,
=FIND(t,Jones, Bob)
Bob) returns
returns an
anerror,
error, because
becauset
t isnt
isnt found
found in
inJones,
Jones, Bob.
Bob.
Parsing Names
Parsing Nameswith
with These
These Text
Text Functions
Functions

The above
The above name-parsing
name-parsingproblem
problem can
can be
be solved
solved with
withthe
thefollowing
following series
series of
of steps:
steps:

1.In
1. In the
the top
topblue
blue cell,
cell, find
findthe
the length
length ofof the
the name
name in in column
column KK with
withthetheLEN
LEN function.
function.
2.In
2. In the
the top
topred
redcell,
cell, find
findthe
the position
position of of the
the comma
comma with withthe
the FIND
FIND function.
function.
3.In
3. In the
the top
topgreen
green cell,
cell, addadd11 totofind
find the
theposition
positionof of the
the space
space after
after the
thecomma.
comma.
4.In
4. In the
the top
toporange
orangecell,
cell, find
find the
thefirst
firstname
namewithwith the
the RIGHT
RIGHT function,
function, using
usingthe
the rightmost
rightmost (10-7)
(10-7)
characters.Make
characters. Make sure
sureyou you use
use cell
cell references
references to to enable
enable copying
copying down.
down.
5.In
5. In the
the top
toptan
tan cell,
cell, find
find the
the last
lastname
namewithwith the
the LEFT
LEFT function,
function, using
usingthethe leftmost
leftmost (6-1)
(6-1) characters.
characters.
Again, use cell references to enable
Again, use cell references to enable copying. copying.

The beauty
The beautyof
of this
this method
method isis that
that you
you have
have to
to do
do itit only
onlyonce,
once, in
in the
the first
first row.
row.Then
Then you
you can
cancopy
copy all
allof
of
theformulas
the formulas down
down forfor the
the rest
restof
of the
the names,
names, even
even ifif there
there are
are thousands
thousands of of them!
them!

Try it!
Try it! Enter
Enter the
the formulas
formulas as
asindicated
indicated by
by the
the above
above steps
steps and
andcopy
copy them
them down.
down.(Scroll
(Scroll to
to the
theright
right for
for
thecorrect
the correct answers.)
answers.)

Now try
Now try aa tougher
tougher one.
one. The
The names
names to
to the
theright
right either
either have
have aa middle
middle initial,
initial, aa first
first initial,
initial, or
or no
no initial.
initial.
See ifif you
See you cancan parse
parse these
these names
names into
intofour
four pieces:
pieces: Last
Lastname,
name, Used
Used name,
name, Initial,
Initial, and
andMiddle
Middleinitial,
initial,
where:
where:
Used name
Used name isis the the name
name(first (firstor
or middle)
middle) the the person
persongoes goes by.
by.
Initial isis the
Initial the single
single initial
initial character,
character, ifif any,
any, or
or isis blank
blankifif there
there isis no no initial.
initial.
Middle initial
Middle initial isis "Yes"
"Yes" ifif the
theinitial
initial isis aamiddle
middle initial,
initial, "No"
"No" ifif ititisisaa first
first initial,
initial, and
and blank
blank ifif there
there isis no
no
initial.
initial.
Asin
As inthe
theprevious
previous exercise,
exercise, you
you can
can have
have other
other "helper"
"helper" columns
columnsas
as needed.
needed. (Hints:
(Hints: (1)
(1) FIND
FIND returns
returns
anerror
an error ifif itit can't
can't find
findthe
therequested
requestedtext.text.(2)
(2) There
There isis an
an ISERROR
ISERROR function
function that
that can
can check
checkwhether
whether aa
cell contains
cell contains an anerror.
error. Scroll
Scroll to
to the
theright
right for
for aasolution.
solution. ))

OK, this
OK, this one
oneisisnot
not easy,
easy, and
anditit requires
requires some
some careful
careful planning
planningand
andlogic.
logic. But
But itit sure
surebeats
beats typing
typingaa
long list
long listof
of hundreds
hundredsoror thousands
thousandsof of names!
names!
Jones, Bob Bob Jones
Davis, Stephen
et such
et such as
as the
theone
one to
to
and a space, and then Thompson, Andy
and a space, and then
the name in
he name in cells
cells L3
L3 Wilson, John
uld have
uld have all
allof
of the
thelast
last Fredericks, Kathy
What would
What wouldyouyoudo?do? IfIf
akemistakes
ake mistakes along
along the
the Williams, Karen
Smith, Tom
xample, notenote that
that Jennings, Peter
xample,
and space,
nd space, and theand thelast
last Benson, Ted
uding the
uding the comma
comma and and Samson, Jason
ee rightmost
rightmost 33
tion, this isis the
on, this the first
firstand
and

text functions. The


ext functions. The
about other
about other text
text

where you
where you can
can

nn characters
characters in
in text.
text. (If
(If

haracters in
haracters in text.
text. (If
(If nn isis
nn characters
characters in
in text.
text. (If
(If

haracters in
haracters in text.
text. (If
(If nn isis

eger.
ger. IfIf nn isismissing,
missing, this
this
nn characters
characters of of text,
text,

henext
he next text
text box
boxto
to see
see

racters (which could


acters (which could be
be

ce of text
e of text to
to be
be found
found
tionreturns
tion returnsthe the
returns an
returns an error.
error. IfIf the
the
artsat
arts at character
character n. n.

haracter in Jones,
aracter in Jones, Bob.
Bob.

gins in
gins in the
the 3rd
3rd

the letter
the letter o
ooccurs
occurs in
in
,3) returns 9,
3) returns 9, because
because

Jones, Bob.
Jones, Bob.
Full name Length Comma Space First name Last name
Jones, Bob
ps:
ps: Davis, Stephen
nction.
ction. Thompson, Andy
Wilson, John
.
rightmost (10-7)
rightmost (10-7) Fredericks, Kathy
Williams, Karen
ost (6-1)
ost (6-1) characters.
characters. Smith, Tom
Jennings, Peter
hen you
hen you can
cancopy
copy all
allof
of Benson, Ted
em!
m! Samson, Jason
(Scroll to
(Scroll to the
theright
right for
for

rst initial, or
st initial, or no
no initial.
initial.
al, andMiddle
l, and Middleinitial,
initial,

d blank
blank ifif there
there isis no
no
Jones, Bob E.
ints: (1)
ints: (1) FIND
FIND returns
returns Davis, F. Stephen
can check
can checkwhether
whether aa
Thompson, Andy
Wilson, John B.
urebeats
ure beats typing
typingaa Fredericks, Kathy C.
Williams, Karen R.
Smith, J. Tom
Jennings, Peter
Benson, Ted C.
Samson, Jason A.
Full name Length Comma Space First name Last name
Jones, Bob 10 6 7 Bob Jones
Davis, Stephen 14 6 7 Stephen Davis
Thompson, Andy 14 9 10 Andy Thompson
Wilson, John 12 7 8 John Wilson
Fredericks, Kathy 17 11 12 Kathy Fredericks
Williams, Karen 15 9 10 Karen Williams
Smith, Tom 10 6 7 Tom Smith
Jennings, Peter 15 9 10 Peter Jennings
Benson, Ted 11 7 8 Ted Benson
Samson, Jason 13 7 8 Jason Samson

Full name Length Comma Space1 Period Space2 Last name Used name
Jones, Bob E. 13 6 7 13 11 Jones Bob
Davis, F. Stephen 17 6 7 9 10 Davis Stephen
Thompson, Andy 14 9 10 #VALUE! #VALUE! Thompson Andy
Wilson, John B. 15 7 8 15 13 Wilson John
Fredericks, Kathy C. 20 11 12 20 18 Fredericks Kathy
Williams, Karen R. 18 9 10 18 16 Williams Karen
Smith, J. Tom 13 6 7 9 10 Smith Tom
Jennings, Peter 15 9 10 #VALUE! #VALUE! Jennings Peter
Benson, Ted C. 14 7 8 14 12 Benson Ted
Samson, Jason A. 16 7 8 16 14 Samson Jason
Initial Middle initial
E Yes
F No

B Yes
C Yes
R Yes
J No

C Yes
A Yes
Background on
Background on Date
Date Functions
Functions

You tend
You tend to
totake
takedates
dates and
and times
times for
for granted,
granted, but
but they
theyappear
appear inin many,
many, ifif not
not most,
most, real-world
real-world
business spreadsheets. They can actually be quite tricky to work with, and
business spreadsheets. They can actually be quite tricky to work with, and a complete treatmenta complete treatment of of
datesand
dates andtimes
timescould
could fill
fill aa long
long chapter
chapter of of aa book.
book. This
This tutorial
tutorial can't
can't cover
cover all
all of
of the
the intricacies
intricacies of
of
Excel-based dates
Excel-based datesand
and times,
times, but but itit does
doesillustrate
illustratesome
some of ofthe
themost
mostuseful
useful methods
methods for for working
working with
with
them.
them.
The first
The first thing
thingtoto realize
realizeisis that
thataa date-time
date-time value
value that
that appears
appears in in aacell
cell as
assomething
something like like 3/14/2004
3/14/2004
4:30PM
4:30 PM isis really
reallystored
stored asasaa number.
number. Excel
Excel refers
refers toto this
this number
number as as the
the serial
serial value.
value. The
Theserial
serial value
value
correspondingto
corresponding to this
this particular
particular date-time
date-timehappens
happens to to be
be 38060.688.
38060.688.The Thevalue
value to to the
theleft
leftof
of the
the
decimal isis the
decimal thenumber
number of of days
days since
since aabase
base date
date (January
(January 1,1, 1900),
1900), andand the
the decimal
decimal part part indicates
indicates
thefraction
the fraction of of time
time through
throughthe the day,
day, starting
starting right
right after
after midnight.
midnight. In Inthis
this example
example 4:30 4:30 PMPM isis 68.8%
68.8% of
of
theway
the way from
from midnight
midnight to to the
thenext
next midnight.
midnight. IfIf the
thedecimal
decimal part
part isis omitted,
omitted, itit isis assumed
assumed to tobebe
midnight. In
midnight. In this
this case,
case, you
you usually
usually format
formatthethe value
value soso that
that only
onlythethe date,
date, not
not the
the time,
time, appears.
appears.

IfIf you
you happen
happen to
to know
know the
thenumbering
numbering system
system forfor dates
dates (that
(thatis,is, you
you somehow
somehow knowknow that
that 38060
38060
corresponds to
corresponds to3/14/2004),
3/14/2004), youyoucould
couldenter
enter the
the number
number 38060
38060 in in aa cell
cell and
and then
then format
format itit to
to look
look like
like
aadate.
date. However,
However, you
you usually
usually enter
enter aa date
datelike
like 3/14/2004
3/14/2004in in aa cell.
cell. Actually,
Actually, there
there are
are several
several formats
formats
Excel recognizes
Excel recognizes as
as dates,
dates, including
including3/14/2004,
3/14/2004, March
March14,14, 2004,
2004, 3-14-04,
3-14-04, andand aafew
few others,
others, butbut
underneaththe
underneath thehood,
hood, they
they are
are all
all stored
storedas
as 38060.
38060.

The same
The same isis true
true for
for date-times,
date-times, such
such as
as 3/14/2004
3/14/20044:30 4:30 PM,
PM, or
or just
justtimes,
times, such
such asas 4:30
4:30PM.
PM.IfIf you
you
enter either of these in a format that Excel recognizes as a date-time or just a time,
enter either of these in a format that Excel recognizes as a date-time or just a time, Excel will Excel will
recognizethat
recognize thatthese
thesearearedate-times
date-times or
or times,
times, but
but itit will
will store
storethem
themas as numbers
numbers (68030.688
(68030.688 or
or 0.688).
0.688).

Bythe
By theway,
way, ifif you
youenter
enter aa date-time
date-time in
in aaformat
format that
that Excel
Excel doesnt
doesnt recognize,
recognize, you
you are
are entirely
entirely out
outof
of
luck. It will simply be stored as a label, with no inherent date-time meaning. And
luck. It will simply be stored as a label, with no inherent date-time meaning. And Excel can be fussy. Excel can be fussy.
For example,
For example, ititdoesnt
doesnt understand
understand 3/14/2004
3/14/2004 4:30PM,
4:30PM, simply
simplybecause
because there
thereisis no
nospace
space between
between
4:30and
4:30 and PM!
PM! On On the
the other
other hand,
hand, Excel
Excel isis smart
smart about
about dates.
dates. ItItwill
will recognize
recognizethat
that9/31/1999
9/31/1999andand
2/29/2003 are
2/29/2003 are notnot datesregardless
datesregardless of of how
how they
they are
are formatted.
formatted.

Try it!
Try it! The
The cells
cells to
to the
theright
right include
include some
somedate-times,
date-times, dates
dates (no
(notimes
times specified),
specified), and
and times
times (no
(no dates
dates
specified), formatted
specified), formatted in in several
several ways.
ways. Format
Formatthese
theseasas numbers
numbers with
with three
threedecimals
decimals toto see
seethe
theserial
serial
values. Then
values. Then reformat
reformat them
themas as date-times
date-times (in
(in any
any formats
formats you
you prefer).
prefer).
ost, real-world
ost, real-world
mplete treatment of
mplete treatment of
ff the
the intricacies
intricacies of
of
hods for
hods for working
working with
with

thing like 3/14/2004


hing like 3/14/2004
alue. The
alue. Theserial
serial value
value
to the
to theleft
leftof
of the
the
ecimal part indicates
cimal part indicates
ple 4:30 PM
le 4:30 PM isis 68.8%
68.8% of
of
assumed to
assumed tobebe
he time, appears.
e time, appears.
know that 38060
now that 38060
en format itit to
n format to look
look like
like
ee are
are several
several formats
formats
few others,
few others, butbut

h as
as 4:30
4:30PM.
PM.IfIf you
you
me, Excel will
me, Excel will
(68030.688 or
(68030.688 or 0.688).
0.688).

uu are
are entirely
entirely out
outof
of
And Excel can be fussy.
And Excel can be fussy.
nospace
no space between
between
hat 9/31/1999and
at 9/31/1999 and

, and
and times
times (no
(no dates
dates
mals to
mals to see
seethe
theserial
serial

3/14/04 1:30 PM
12/31/1901
3:50
12:00 PM
29-Feb-96
9/24/46 14:45
Y2K Problem:
Y2K Problem: 2-Digit
2-Digit Years
Years

Do you
Do you remember
remember the the Y2K
Y2K problem
problem that
that worried
worried everyone
everyone inin late
late 1999?
1999? The The
problem was that a large number of dates, in all kinds of systems,
problem was that a large number of dates, in all kinds of systems, listed 2-digit listed 2-digit
years, such
years, suchasas 85
85instead
instead of of 1985.
1985. How
How would
would systems
systems know
know whether
whether 05 05meant
meant
1905 or
1905 or 2005?
2005? Fortunately,
Fortunately, the thepredicted
predicteddisaster
disaster didnt
didnthappen,
happen, but
butthere
thereisis still
still
aa Y2K
Y2K problem
problem because
because of of the
the ambiguity
ambiguity 2-digit
2-digit years
years can
can create.
create.Excel
Excel handles
handlesit, it,
at least for now, by interpreting a 2-digit year less than 30 as being
at least for now, by interpreting a 2-digit year less than 30 as being in the 21 in the 21 stst
century, and
century, and all
all others
others as as being
beingin in the
the 20
20thth century.
century.ForFor example,
example, itit interprets
interprets
3/14/17 as
3/14/17 as March
March 14,14, 2017
2017and and 5/20/72
5/20/72as as May
May 20,
20, 1972.
1972.OfOf course,
course, the the easiest
easiest
way to
way toavoid
avoid the
the ambiguity
ambiguity isis to touse
use 4-digit
4-digit years
years whenever
whenever youyou enter
enter dates.
dates.ThisThis
is the lesson of
is the lesson of Y2K!Y2K!

Tryit!
Try it! Enter
Enter aa date
date to
to the
the right
right such
such as
as 3/14/29
3/14/29 (the
(thelast
last two
two digits
digits less
less than
than 30).
30).
Then enter
Then enter another
another date
date such
such as
as 5/20/30
5/20/30 (the
(thelast
last two
two digits
digits greater
greater than
than oror
equal to
equal to 30).
30).Watch
Watch how
how Excel
Exceltransforms
transforms the
the year
year automatically.
automatically. Do Doyou
you see
see how
how
this could
this couldbe be aaproblem
problem ifif you
you really
really meant
meant 3/14/29
3/14/29to to be
bethe
thebirthday
birthday ofofaa
person born
person born inin 1929?
1929?
TODAY, NOW
TODAY, NOW Functions
Functions

Excel has
Excel has two
two useful
useful functions,
functions, TODAY
TODAY and
andNOW,
NOW, for
for automatically
automaticallyentering
entering the
the
current date or the current date and time
current date or the current date and time . .

To use
To use the
theTODAY
TODAY function:
function:

Enter the
Enter theformula
formula =TODAY()
=TODAY() inin any
any blankblank cell.
cell.(The
(The blank
blank parentheses
parentheses are
are
necessary.) ItIt returns
necessary.) returns the
the current
current date.date.IfIf you
youopen
open this
thisspreadsheet
spreadsheet tomorrow,
tomorrow, itit
will list
will listtomorrows
tomorrowsdate,
date, that
that is,
is, itit will
will update
updateeach each day.
day.

To use
To use the
theNOW
NOW function:
function:

Enter the
Enter theformula
formula =NOW()
=NOW() in inany
anyblank
blank cell.
cell. (Again,
(Again, the
the blank
blank parentheses
parentheses are
are
necessary.) ItIt returns
necessary.) returns the
the current
current date
date and
and time.
time.
Tryit!
Try it! Enter
Enter the
theTODAY
TODAY and and NOW
NOW functions
functions in
in column
column L.L. Then
Thenformat
format result
resultofof
NOWas
NOW as time
time onlyno
onlyno date.date. After
After you
you have
have worked
worked aa few
few other
other exercises
exercises in
in this
this
tutorial, come
tutorial, comeback
back toto this
this worksheet
worksheet and
and see
see whether
whether the
the time
timehas
has changed.
changed.
(You might
(You might have
havetoto force
forceaa recalculation
recalculation to
tosee
see the
the change.
change. You
You can
can do
do this
thisby
by
pressingthe
pressing theF9F9 key.)
key.)
Today's date
Current time
YEAR, MONTH,
YEAR, MONTH, DAY
DAY Functions
Functions

IfIf aa cell
cell contains
contains aadate,
date, ititisis easy
easyto
to strip
strip off
off the
the year,
year, month,
month, and
andday
daywith
with the
the
YEAR, MONTH, and DAY functions. In all of the following examples,
YEAR, MONTH, and DAY functions. In all of the following examples, datecell refers datecell refers
to aacell
to cell that
that contains
contains aadate.
date.

To use
To use the
theYEAR
YEAR function:
function:

Enter the
Enter theformula
formula =YEAR(datecell).
=YEAR(datecell). This
Thisreturns
returns aa 4-digit
4-digit year
year such
such as
as 1993.
1993.

To use
To use the
theMONTH
MONTH function:
function:

Enter the
Enter theformula
formula =MONTH(datecell).
=MONTH(datecell). This This returns
returns aamonth
monthfrom
from 11 (January)
(January) to
to
12(December).
12 (December). IfIf you
youwant
want to
toget
get the
thename
nameof of the
the month,
month, such
such as
as June,
June, use
useaa
VLOOKUP function,
VLOOKUP function, as
as indicated
indicated in
in the
the following
following exercise.
exercise.
To use
To use the
theDAY
DAY function:
function:

Enter the
Enter theformula
formula =DAY(datecell).
=DAY(datecell). This
This returns
returns the
the day
day of
of the
the month,
month, from
from 11to
to
the number of days in that particular month.
the number of days in that particular month.
Tryit!
Try it! For
For each
each date
datestarting
startingin
in cell
cell K4,
K4, return
return the
the year,
year, month
month number,
number, month
month
name, and
name, and day
day in
in columns
columns L-O.
L-O.For
For the
the month,
month, use
use the
the lookup
lookuptable
table supplied.
supplied.Do
Do
you recognize these infamous dates? Try one more: your own
you recognize these infamous dates? Try one more: your own birthdate. birthdate.

WEEKDAY Function
WEEKDAY Function
TheWEEKDAY
The WEEKDAY function
functiontakes
takesaa date
date and
and returns
returns the
theday
day of
of the
theweek,
week, as
as an
an index,
index,
of that
of thatdate.
date.

To use
To use the
theWEEKDAY
WEEKDAY function:
function:

Enter the
Enter theformula
formula =WEEKDAY(datecell).
=WEEKDAY(datecell). This
This returns
returns aanumber
number from
from 11 toto 7,
7,
where 11refers
where refers to
toSunday,
Sunday, 22 to
toMonday,
Monday, and
and so
so on.
on.IfIfyou
youwant
want totoget
get the
thename
nameof of
theday,
the day, such
such as
as Thursday,
Thursday, you
you must
must use
useaa VLOOKUP
VLOOKUPfunction,
function, as
as indicated
indicatedin inthe
the
following exercise.
following exercise.
Tryit!
Try it! Continue
Continue the
the previous
previous exercise
exercise by
by filling
filling in
in the
the weekday
weekday numbers
numbers andand
weekdaynames
weekday names inin columns
columns PP and
and Q.
Q. Use
Use the
the lookup
lookup table
table supplied
supplied for
for day
day
names.
names.
Date Year Month number Month name Day Weekday number Weekday name
9/11/2001
1/28/1986
11/22/1963
8/6/1945
12/7/1941
4/14/1912

Lookup table - months Lookup table - days


1 January 1 Sunday
2 February 2 Monday
3 March 3 Tuesday
4 April 4 Wednesday
5 May 5 Thursday
6 June 6 Friday
7 July 7 Saturday
8 August
9 September
10 October
11 November
12 December
DATEDIF Function
DATEDIF Function

Becausedates
Because dates are
are stored
stored as
as numbers,
numbers, itit isis possible
possible to
to perform
performarithmetic
arithmetic on
on
them. Subtraction makes special sense. If you subtract one date from
them. Subtraction makes special sense. If you subtract one date from another, another,
you find
you find the
thenumber
number of of days
days between
betweenthem.
them.

Youcan
You can do
do this
thisby
bysimple
simplesubtraction
subtraction ofof cells,
cells, or
or you
you can
can have
have more
more control
control with
with
the DATEDIF function. If you use simple subtraction, you automatically
the DATEDIF function. If you use simple subtraction, you automatically get the get the
difference in
difference in days.
days. For
For example,
example, ifif you
you subtract
subtract 11/25/2004
11/25/2004 from
from11/30/2004,
11/30/2004,
you get
you get 5.
5.

TheDATEDIF
The DATEDIF function
function provides
provides more
moreoptions.
options.(Evidently,
(Evidently, DATEDIF
DATEDIF has
has been
been in
in
Excel for
Excel for years,
years, but
but its
itsdocumentation
documentation in
in online
online help
help has
has been
beensporadic.
sporadic. See
See the
the
interesting article
interesting articleat
at http://www.cpearson.com/excel/datedif.htm.)
http://www.cpearson.com/excel/datedif.htm.)
To use
To use the
theDATEDIF
DATEDIF function:
function:

Enter the
Enter theformula
formula =DATEDIF(earlierdate,laterdate,interval),
=DATEDIF(earlierdate,laterdate,interval), where where interval
interval can
can
be y,
be y, m,
m, d,d, or
or aa few
few other
other options
options not
notcovered
covered here.
here. IfIf interval
interval isis y
y (quotes
(quotes
required), this
required), this returns
returns the thenumber
number ofof years
years between
betweenthe
the two
two dates.
dates.Similarly,
Similarly, ifif
interval isis m
interval m oror d,
d, itit returns
returnsthe
the number
number of ofmonths
months or
or number
number of ofdays
days
between the
between the two
two dates.
dates.

Tryit!
Try it! Use
Usesimple
simple subtraction
subtraction of
of cells
cells to
to find
findthe
the number
number ofof days
days between
between the the
twodates
two dates to to the
the right.
right.Then
Thenuse
use DATEDIF
DATEDIF withwith the
thethree
threeoptions
optionsindicated
indicated to toget
get
thenumber
the number of of days,
days, months,
months, and
and years
years between
between the the two
two dates.
dates.(Scroll
(Scroll to
to the
the
right for
right for the
the answers.)
answers.)

Notethat
Note that when
whenyou
youdo
do date
date subtraction,
subtraction, you
you sometimes
sometimes need need to
to reformat
reformatthe the
answer as
answer as an
aninteger.
integer.For
For some
some odd
oddreason,
reason, Excel
Excel tends
tends to
to format
format itit as
asaa date.
date.

Notealso
Note also that
that DATEDIF
DATEDIF returns
returns integer
integer values.
values.For For example,
example, you you might
might expect
expect thethe
formula=DATEDIF(1/1/2010,12/1/2010,"y")
formula =DATEDIF(1/1/2010,12/1/2010,"y") to to return
returnsomething
something close
close to
to 0.9.
0.9.ItIt
doesn't. In
doesn't. In fact,
fact, itit doesn't
doesn'teven
even round;
round; itit truncates
truncates (in
(in this
this case,
case, to
to 0).
0).
Dates of last two physical exams

First exam 4/5/2009


Next exam 7/15/2011

Days (subtraction)
Days (DATEDIF)
Months (DATEDIF)
Years (DATEDIF)
Days (subtraction) 831
Days (DATEDIF) 831
Months (DATEDIF) 27
Years (DATEDIF) 2
DATE Function
DATE Function

TheDATE
The DATEfunction
function takes
takes three
three numerical
numerical arguments,
arguments, aa year,
year, aamonth,
month, and
and aaday,
day,
and it returns the corresponding date. The important part is that Excel
and it returns the corresponding date. The important part is that Excel recognizesrecognizes
theresult
the result as
as aa date,
date, which
which you
you can
can then
then format
formatin
in any
anydate
date format
formatyou
you like.
like.

To use
To use the
theDATE
DATE function:
function:

Enter the
Enter theformula
formula =DATE(year,month,day),
=DATE(year,month,day), wherewhere year
year isis aa 4-digit
4-digit year,
year, month
month isis
aa number
number from
from 11to
to 12,
12, and
and day
day isis aaday
dayfrom
from11 to
tothe
the number
number of of days
days in
inthe
the
month.
month.
This function
This functioncan canbebe very
veryuseful
useful for
for manipulating
manipulating dates. dates. ForFor example,
example, ititcan
canbebe
usedto
used to find
find your
your next
next birthday,
birthday, given
givenyour your birthdate,
birthdate, as as illustrated
illustrated in
in cell
cell L4.
L4.The
The
formulain
formula incell
cell L4
L4 isis aalong
long one,
one, but
but itit isis simple
simple logic.
logic. This
This person's
person's next
next birthday
birthday
will certainly
will certainly bebe on
on July
July 22.
22. The
The only
onlyquestion
question isis whether
whether itit will
will be
bein
inthe
the current
current
year or
year or the
thenext
next year.
year.The TheIFIF function
functionchecks
checks forfor this.
this. Note
Note that
that YEAR(TODAY())
YEAR(TODAY())
returns the
returns the year
year corresponding
corresponding to to today's
today's date.date.

Tryit!
Try it! Enter
Enter your
your birthdate
birthdate in in the
theblue
blue cell
cell to
to the
theright
right and
and then
thencalculate
calculateyour
your
current age
current age in
in the
thered
redcell.
cell. (Scroll
(Scroll to
to the
the right
right for
for the
theanswer.)
answer.)

DATEVALUE Function
DATEVALUE Function

TheDATEVALUE
The DATEVALUEfunction
function can
can bebe aa real
real life-saver.
life-saver. ItIttakes
takesaa date
date stored
storedas as text
textand
and
returns the
returns the corresponding
corresponding serial
serial value,
value, which
whichyouyoucan canthen
thenformat
format asas aa date.
date. Why
Why
isis this
this important?
important? Suppose
Suppose youyou have
have aa lotlot of
of data
data stored
storedin insome
some type
type of
of legacy
legacy
system in
system inyour
your business,
business, and
and you
you areare somehow
somehow able able to to dump
dumpititinto
into Excel.
Excel. The
The
chances are that all dates will be imported as text. That is, a
chances are that all dates will be imported as text. That is, a cell value will lookcell value will look
somethinglike
something like 5/20/2001,
5/20/2001, but but Excel
Excel wont
wont recognize
recognize itit asas aa date.
date.Without
Without the the
DATEVALUEfunction,
DATEVALUE function, you
you would
would have
have toto retype
retypeall
all ofof the
the dates!
dates!However,
However,
DATEVALUEsaves
DATEVALUE saves you
you this
this mind-numbing
mind-numbing work. work.

To use
To use the
theDATEVALUE
DATEVALUE function:
function:

Enter the
Enter theformula
formula =DATEVALUE(datetext),
=DATEVALUE(datetext), where
where datetext
datetext refers
refers to
to aadate
datestored
stored
as text. Then format the result as a date.
as text. Then format the result as a date.
Tryit!
Try it! Create
Createdates
dates inin column
column LL corresponding
correspondingto
to the
the text
text values
values in
in column
column KK that
that
happen to
happen tolook
look like
like dates.
dates.
Birthdate Next birthday
7/22/1976 7/22/2017

Birthdate Age

Dates imported from a legacy system

Nov 25, 1997


Nov 26, 1997
Nov 29, 1997
Dec 1, 1997
Dec 3, 1997
Birthdate Age
8/16/1976 40
NETWORKDAYS (and
NETWORKDAYS (and NETWORKDAYS.INTL)
NETWORKDAYS.INTL) Functions
Functions

TheNETWORKDAYS
The NETWORKDAYS countscounts the the number
number of of workdays,
workdays, not
not including
includingweekends
weekends or
or
specified holidays between a given start date and a given end date.
specified holidays between a given start date and a given end date. You can You can
specify the
specify theholidays
holidays in
in aalist
list somewhere
somewhere in in the
the worksheet.
worksheet.

Tryit!
Try it! Enter
Enter aa formula
formulaof of the
theform
form =NETWORKDAYS(startdate,
=NETWORKDAYS(startdate, finishdate,
finishdate,
holidaydates) that finds the number of workdays between
holidaydates) that finds the number of workdays between the dates the dates listed
listed to
to the
the
right. AAfew
right. few holidays
holidays have
have been
been listed,
listed, but
but you
you can
can add
add to
to this
this list
list ifif you
you like.
like.
(Scroll to
(Scroll to the
theright
right for
for the
the answer.)
answer.)

IfIf you
youare
are using
using Excel
Excel 2010,
2010, you
youwill
will see
seeaa new
new andandmore
more general
general function,
function,
NETWORKDAYS.INTL.This
NETWORKDAYS.INTL. This has
has an
anadditional
additional (third)
(third) argument
argument that
that lets
letsyou
you deal
deal
with weekends
with weekends ininaa variety
variety of
ofways.
ways.ForFor example,
example, ifif you
youenter
enter the
the code
code 11
11 for
for this
this
argument (which
argument (whichyou
you can
canfind
find in
in online
online help),
help), the
thefunction
function will
will return
return all
all days
days
except for
except for Sundays
Sundays and
andholidays.
holidays.

WORKDAY (and
WORKDAY (and WORKDAY.INTL)
WORKDAY.INTL) Functions
Functions

TheWORKDAY
The WORKDAY function
functionisis similar,
similar, but
but its
its objective
objective isis slightly
slightlydifferent.
different.Now
Now you you
specify aa start
specify start date,
date, the
the number
number of of workdays
workdays required
required to to finish
finish aaproject,
project, and andaa
list of
list of holidays.
holidays. The
The function
function returns
returns the
the first
first workday
workday after
after the
the project
project isis finished.
finished.
ItItdoesn't
doesn't count
count weekends.
weekends.

Tryit!
Try it! Enter
Enter aa formula
formulaof of the
theform
form =WORKDAY(startdate,
=WORKDAY(startdate, daysreqired,
daysreqired,
holidaylist) that
holidaylist) that finds
finds the
the first
first workday
workday available
availableafter
after aaproject
project isis finished,
finished, given
given
thedata
the data to
to the
the right.
right. What
What day day of
of the
the week
week isis the
the result?
result?

As you
As you might
might guess,
guess, there
thereisis an
an additional
additional function
function WORKDAY.INTL
WORKDAY.INTL in in Excel
Excel 2010,
2010,
similar to
similar to NETWORKDAYS.INTL,
NETWORKDAYS.INTL,that that lets
lets you
you enter
enter aa code
code for
for the
thehandling
handlingof of
weekends.
weekends.
Start date 6/1/2010 Holidays
Finish date 3/25/2011 Independence Day 7/4/2010
Thanksgiving 11/25/2010
Network days 11/26/2010
Christmas, New Years 12/24/2010
12/25/2010
12/31/2010
1/1/2011

Start date 6/1/2010 Holidays


Days required 175 Independence Day 7/4/2010
Thanksgiving 11/25/2010
First available workday 11/26/2010
Christmas, New Years 12/24/2010
12/25/2010
12/31/2010
1/1/2011
NETWORKDAYS 210
NETWORKDAYS.INTL 250

WORKDAY 2/7/2011
WEEKDAY 2 Monday

WORKDAY.INTL 12/27/2010
WEEKDAY 2 Monday
Background on
Background on Statistical
Statistical Functions
Functions

There are
There are many
many statistical
statistical functions
functions built
builtinto
into Excel.
Excel. The
The simplest
simpleststatistical
statistical
function, the AVERAGE function, has already been discussed
function, the AVERAGE function, has already been discussed in a previous in a previous
worksheet.(Statisticians
worksheet. (Statisticiansoften
often call
call this
this the
the mean,
mean, oror the
the sample
sample mean,
mean, but
but itit isis
simply the
simply theaverage
averageof of aaset
set of
of numbers.
numbers. And And there
there isis no
no Excel
Excelfunction
functionnamed
named
MEAN.) This
MEAN.) This section
section discusses
discusses aafew
few other
other common
commonstatistical
statistical functions.
functions.Actually,
Actually,
there are many more. To see the possibilities, click the f button
there are many more. To see the possibilities, click the fxxbutton and look at and look at the
the
Statistical category.
Statistical category.
Microsoftadded
Microsoft added some
somenew
new statistical
statistical functions
functions (and
(andrenamed
renamed some
some old old ones)
ones) in in
Excel 2010.
Excel 2010.See
See the
the New
New and
and Renamed
RenamedFunctions
Functions worksheet
worksheet in
in this
this tutorial
tutorial for
for
moreinformation
more information about
about the
the changes.
changes.
MAX, MIN
MAX, MIN Functions
Functions

TheMAX
The MAX function
functionreturns
returns the
thelargest
largest numeric
numeric value
value in
inaa range.
range. Similarly,
Similarly, the
theMIN
MIN
function returns the smallest numeric value in a range.
function returns the smallest numeric value in a range.
To use
To use MAX
MAX and
and MIN
MIN functions:
functions:

Enter the
Enter theformula
formula =MAX(range)
=MAX(range) or or =MIN(range)
=MIN(range) where
where range
range isisany
any range.
range.These
These
produce the
produce theobvious
obvious results:
results: the
the maximum
maximum (or
(or minimum)
minimum) value
value ininthe
the range.
range.

Tryit!
Try it! Use
Usethe
theMAX
MAX and
andMIN
MIN functions
functions to
to fill
fill in
in the
the blue
blue range
range to
to the
the right.
right.

Notethat
Note that MAX
MAX and
and MIN
MIN work
workonly
onlyonon numeric
numeric data.
data. IfIf you
youhave
have aa list
listof
of names,
names,
you might
you mightexpect
expect MIN
MIN and
and MAX
MAX to
to return
return the
the first
first and
andlastlast in
in alphabetical
alphabetical order,
order,
but they
but they don't.
don't. Too
Too bad!
bad! (There
(Thereare
are two
two other
other functions
functions called
calledMAXA
MAXA andand MINA,
MINA,
but they
but they don't
don'tappear
appear to
to be
bevery
very useful.)
useful.)
Sales rep Allison Baker Jones Miller Smith Taylor
Jan sales $3,700 $2,400 $2,300 $3,000 $3,800 $3,700
Feb sales $2,600 $2,200 $2,400 $2,800 $3,600 $2,300

Min sales Max sales


Jan
Feb
MEDIAN Function
MEDIAN Function

Themedian
The medianisis the
themiddle
middle value
valuein
inaa set
set of
of nn numbers,
numbers, in inthe
thesense
sensethat
that half
half are
are
above it and half are below it. More precisely, when the values
above it and half are below it. More precisely, when the values are sorted in are sorted in
increasing order,
increasing order, itit isis the
themiddle
middle value
valueifif nn isis odd,
odd, and
andititisisthe
the average
average of
of the
the two
two
middle values
middle values ifif nn isis even.
even.Fortunately,
Fortunately, Excel
Excel takes
takes care
careofof the
the details
details with
with the
the
MEDIAN function.
MEDIAN function.

To use
To use the
theMEDIAN
MEDIAN function:
function:

Enter the
Enter theformula
formula =MEDIAN(datarange),
=MEDIAN(datarange), where
where datarange
datarange isis any
any range
range
containing data.
containing data.
Notethat
Note that ifif datarange
datarange contains
contains labels
labels or
or blank
blank cells,
cells, these
these are
areignored
ignoredwhen
when
calculatingthe
calculating the median.
median.This
This isis true
true for
for other
other statistical
statistical functions.
functions.
Tryit!
Try it! Find
Findthe
the median
median of
of the
thedata
data in
in column
column K.
K.Does
Does itit equal
equal the
the average?
average? Why
Why
or why
or whynot?
not?

QUARTILE Function
QUARTILE Function

Thevalues
The valuesininaa data
dataset
set are
areoften
often ranked
rankedininsome
some way.
way. For
For example,
example, ifif you
you take
take
theSAT
the SAT exam
exam to to get
get into
intocollege,
college, you
you essentially
essentially learn
learn your
your ranking
ranking by
by aa
percentile.IfIf you
percentile. you are
areatat the
the85
85ththpercentile,
percentile, you
you know
know that
that 85%
85% of
of all
all people
people
scored lower
scored lower than
than you,
you, and
and only
only 15%
15% scored
scoredhigher.
higher. Excel
Excel has
hastwo
two useful
useful
functions for
functions for finding
finding this
thistype
type of
of information:
information: PERCENTILE
PERCENTILE and and QUARTILE.
QUARTILE.

TheQUARTILE
The QUARTILE function
functionisisprobably
probablythetheeasiest
easiesttoto understand.
understand. Imagine
Imaginethatthat you
you
have 1000
have 1000 scores.
scores. You
Yousort
sortthem
them from
fromlow
low to
to high
high andand then
then divide
dividethem
theminto
into 44
sets of
sets of 250
250scores
scores each,
each, where
wherethe
thefirst
firstset
set contains
contains thethe smallest
smallest scores,
scores, the
the
second set
second set contains
contains the
thenext
next smallest
smallest scores,
scores, and
andso so on.
on. The
The 1st,
1st, 2nd,
2nd, and
and 3rd
3rd
quartiles are the breakpoints between these sets. For example, 25%
quartiles are the breakpoints between these sets. For example, 25% of the scores of the scores
arebelow
are below the
the1st
1stquartile,
quartile, and
and 75%
75% are
are above
above it.
it. By
Bydefinition,
definition, the
the 2nd
2nd quartile
quartile isis
themedian.
the median.

To use
To use the
theQUARTILE
QUARTILE function:
function:

Enter the
Enter theformula
formula =QUARTILE(datarange,k),
=QUARTILE(datarange,k), where
where kk isis 1,
1, 2,
2, or
or 3.
3. For
For example,
example, ifif
you enter
you enter 33 for
for k,
k, you
youget
get the
the3rd
3rd quartile.
quartile.

Tryit!
Try it! Find
Findall
all three
threequartiles,
quartiles, Q1,
Q1, Q2,
Q2, and
and Q3,
Q3, for
for the
thedata
datain
incolumn
column K.
K.

PERCENTILE Function
PERCENTILE Function

ThePERCENTILE
The PERCENTILE function
function takes
takes any
any percentage,
percentage, expressed
expressed asas aa decimal
decimalnumber,
number,
andreturns
and returns the
thevalue
valuesuchsuch that
thatthe
the given
given percentage
percentage of
of all
all values
values isisbelow
below this
this
value.For
value. For example,
example, ifif the
the percentage
percentageisis 10%
10% (0.10)
(0.10) and
andthe
thePERCENTILE
PERCENTILEfunction
function
PERCENTILE Function
PERCENTILE Function

ThePERCENTILE
The PERCENTILE function
function takes
takes any
any percentage,
percentage, expressed
expressed as as aa decimal
decimalnumber,
number,
and returns the value such that the given percentage of all values
and returns the value such that the given percentage of all values is below this is below this
value.For
value. For example,
example, ifif the
the percentage
percentageisis 10%
10% (0.10)
(0.10) and
andthe
thePERCENTILE
PERCENTILEfunction
function
returns 45,
returns 45, you
you know
know that
that10%
10% ofof all
all values
values in
in the
thedata
data set
set are
are below
below 4545 and
and 90%
90%
areabove
are aboveit.
it.

To use
To use the
thePERCENTILE
PERCENTILEfunction:
function:

Enter the
Enter theformula
formula =PERCENTILE(datarange,pct),
=PERCENTILE(datarange,pct), where
where pct
pct isis any
anypercentage
percentage
expressed as a decimal, such as 0.10 for 10%.
expressed as a decimal, such as 0.10 for 10%.
Tryit!
Try it! Find
Findthe
the requested
requestedpercentiles
percentiles for
for the
the data
data in
in column
column K.
K. For
For example,
example, P10
P10
indicates the
indicates the 10th
10th percentile.
percentile. Do
Doyou
yousee
see the
therelationship
relationshipbetween
between the
the quartiles
quartiles
andcertain
and certain percentiles?
percentiles?

Technical Note
Technical Note About
About QUARTILE
QUARTILE and
and PERCENTILE
PERCENTILE Functions
Functions

TheQUARTILE
The QUARTILE and and PERCENTILE
PERCENTILE functions
functions are
are typically
typically used
used on
on data
data sets
sets with
with aa
largenumber
large number of of observations.
observations. IfIf they
they are
are used
used on on aavery
very small
small data
dataset,
set, you
you might
might
be surprised
be surprised at at the
the results.
results. In
Infact,
fact, you
youmight
might even
even disagree
disagreewith
with them.
them. For
For
example, ifif the
example, thedata
data set
set has
has the
the 55 values
values 10,
10, 20,
20, 30,
30, 40,
40, and
and 50,
50, Excels
Excels
PERCENTILE function indicates that the 10 percentile is 14. This isiscertainly
PERCENTILE function indicates that the 10 th
th percentile is 14. This certainlynot
not aa
very intuitive
very intuitive answer,
answer, andand you
you might
might disagree
disagree with
withit,
it, but
but why
why anyone
anyonewould
would
want the
want the 10
10thth percentile
percentileof of aa5-value
5-valuedata
datasetset in
in the
thefirst
firstplace?
place?
33 Average
3 Median
0
1 Quartiles
4 Q1
14 Q2
5 Q3
41
3 Percentiles
5 P01
9 P05
1 P10
0 P25
22 P50
10 P75
5 P90
13 P95
7 P99
6
3
9
5
14
7
27
10
7
3
11
15
35
9
0
5
6
11
13
4
17
3
19
4
5
1
21
4
16
6
18
18
2
3
17
7
9
6
4
2
7
3
0
14
2
4
24
12
1
4
36
3
0
2
4
12
7
2
1
16
5
31
15
29
12
5
4
5
22
14
7
7
19
38
15
45
1
4
14
3
16
4
Excel has
Excel has aanumber
number of of other
other statistical
statistical functions,
functions, including
including those
thosefor
for measuring
measuring
theamount
the amount of of variability
variabilityininaa set
set of
of numbers.
numbers.The Themost
mostwidely
widely used
used measures
measuresof of
variability are
variability are variance
variance and
and standard
standard deviation,
deviation, and
and Excel
Excel implements
implements these
these with
with
theVAR
the VAR and
and STDEV
STDEV functions.
functions.(These
(Thesefunctions
functions calculate
calculate the
the sample
sample variance
variance and
and
standard deviation.
standard deviation. There
There are
are similar
similar functions,
functions, VARP
VARPand and STDEVP,
STDEVP, for
for calculating
calculating
the population
the population variance
varianceandand standard
standard deviation.
deviation. For
For large
large data
data setsover
setsover 100 100
values, saythe
values, saythe sample
sampleand andpopulation
population measures
measures arearepractically
practically the
the same.)
same.)

Thevariance
The variance isis essentially
essentiallythe the average
average of of the
thesquared
squared deviations
deviations from
fromthethe mean,
mean,
andthe
and the standard
standarddeviation
deviation isis the
the square
square rootroot of
ofthe
thevariance.
variance.Each
Each measures
measures
variability, but
variability, but standard
standarddeviation
deviation isis easier
easier toto understand
understand because
becauseititisis expressed
expressed
in the same units as the datadollars, for example. In addition,
in the same units as the datadollars, for example. In addition, many data sets many data sets
have the
have the property
property thatthat about
about 68% 68% ofof the
thedata
data are
are within
within one
one standard
standarddeviation
deviation
of the
of the mean,
mean, aboutabout 95%
95% are
arewithin
within two
two standard
standard deviations
deviations of
of the
the mean,
mean, and
and
virtually all
virtually all of
of the
the data
data are
are within
within three
threestandard
standard deviations
deviations of
of the
the mean.
mean. (These
(These
rules of
rules of thumb
thumb typically
typicallyhold
holdwhen
when thethe distribution
distributionof of values
values follows
follows aasymmetric,
symmetric,
bell-shaped curve,
bell-shaped curve, that
that is,
is, the
thenormal
normal distribution.)
distribution.)

To use
To use the
theVAR
VAR function:
function:

Enter the
Enter theformula
formula =VAR(datarange).
=VAR(datarange). This
This isis equivalent
equivalent to
to
=(STDEV(datarange))^2, the
=(STDEV(datarange))^2, the square
square of
of the
the standard
standard deviation.
deviation.

To use
To use the
theSTDEV
STDEV function:
function:

Enter the
Enter theformula
formula =STDEV(datarange).
=STDEV(datarange). This
This isis equivalent
equivalent to
to
=SQRT(VAR(datarange)), the
=SQRT(VAR(datarange)), the square
square root
root of
ofthethe variance.
variance.

Tryit!
Try it! Find
Findthe
the mean,
mean, variance,
variance, andandstandard
standard deviation
deviationof of the
thedata
datain
incolumn
column K.
K.
Then use
Then useCOUNTIF
COUNTIF to
to find
find thethe percentage
percentage of
of values
values that
that are
arewithin
within one
onestandard
standard
deviation of
deviation of the
themean.
mean. IsIs ititabout
about68%?
68%?(Scroll
(Scroll to
to the
the right
rightto to see
seethe
theanswers.)
answers.)
1034.44 Mean
877.35 Variance
794.42 Standard deviation
828.45
765.9 % within 1 stdev
1088.95
786.05
1523.02
920.48
777.23
1247.63
1117.87
1157.3
641.35
520.49
586.68
952.22
878.36
1582.12
807.99
913.13
1051.65
628.44
651.86
843.55
1233.37
1036.55
543.17
866.31
883.25
1285.68
650.44
1412.4
1105.44
671.55
1077.21
1471.87
1362.55
1044.37
601.52
1256.48
1069.69
407.54
1609.11
1141.03
972.54
851.91
1324.67
1061.09
809.91
655.81
1224.02
1105.52
1102.63
342.62
642.01
762.48
945.73
1431.55
695.66
871.12
827.21
1468.62
863.17
582.4
919.07
1314.83
1418.85
909.82
1086.11
620.14
668.74
598.66
1175.09
1139
1369.23
618.31
693.67
1341.85
1479.33
477.41
962.29
686.64
1495.96
1101.87
1018.6
1027.43
921.99
868.49
856.14
724.87
1345.72
1127.91
1467.66
918.88
997.56
965.11
1059.32
1157.35
1116.73
1410.39
786.62
1477.32
1328.5
753.26
905.17
821.06
1052.57
926.89
579.01
873.54
1100.79
727.32
718.17
948.09
866.89
684.5
1391.63
678.82
961.36
1023.22
851.44
1247.63
1373.37
1177.79
929.79
690.18
736.95
1293.14
1134.24
1316.3
1440.09
1249.47
787.9
1320.84
1263.38
1212.95
1081.63
1214.14
1367.41
1579.93
1405.68
965.25
1081.01
713.61
1033.28
999.4
361.42
721.3
1052.62
1094.3
937.92
1217.14
225.9
707.88
856.16
949.8
1510.56
1234.83
1147.42
820.95
1049.69
915.41
862.87
1017.05
763.08
978.67
1357.03
1279.62
1361.16
952.66
523.33
1375.14
545.6
847.12
1464.07
1113.21
1292.26
634.98
651.65
602.12
1367.6
891.63
1197.37
1355.34
904.44
1638.89
1325.24
892.26
1553.37
697.54
1127.03
854.27
810.98
902.46
623.26
952.45
853.4
1029.52
1172.72
Mean 999.77
Variance 83102.38
St Dev 288.27

Mean - Stdev 711.50


Mean + Stdev 1288.05
Pct with 1 stdev of mean
# less 36
# greater 40
62%
CORREL (Correlation)
CORREL (Correlation) and
and COVAR
COVAR(Covariance)
(Covariance) Functions
Functions

IfIf there
therearearetwotwocolumns
columns of of data
data that
thatare are matched
matched in in aa particular
particular way,way, such
such as as
sales of two company products in a given month, it
sales of two company products in a given month, it is often useful to see how is often useful to see how
they are
they arerelated.
related. IfIf one
oneisis unusually
unusuallylarge, large, does
does thethe other
other tendtend to
tobebe unusually
unusually
large? Unusually
large? Unusually small?
small? The The statistical
statistical measure
measure for for this
this isis correlation,
correlation, and and itit can
can
be calculated
be calculated with with thethe CORREL
CORREL function.
function. AA correlation
correlation isis aa number
number between
between-1 -1
and +1. If the correlation is positive, the two sets of numbers
and +1. If the correlation is positive, the two sets of numbers tend to go together. tend to go together.
IfIf one
one isis small,
small, the
theother
other tends
tends toto be
be small;
small; ifif one
oneisis large,
large, thethe other
other tends
tends to to bebe
large. Exactly
large. Exactlythe the opposite
opposite isis true
true ifif the
the correlation
correlation isis negative.
negative. In In this
this case,
case, the
the
twosets
two sets of ofnumbers
numbers tend tend totogogo in
in opposite
opposite directions.
directions. TheThe magnitude
magnitudeof of the
the
correlation indicates the strength of the relationship
correlation indicates the strength of the relationship between the two sets of between the two sets of
numbers.There
numbers. There isis aastrong
strong relationship
relationship (positve
(positve or or negative)
negative) ifif the
thecorrelation
correlationisis
closeto
close to -1 -1or
or +1.
+1.TheThe relationship
relationship isis muchmuch weaker,
weaker, or or nonexistent,
nonexistent, ififthe the
correlationisisclose
correlation close to to0.
0.
To calculate
To calculate aacorrelation
correlationbetween
between two
two sets
sets of
of numbers:
numbers:

Enter the
Enter theformula
formula =CORREL(range1,range2),
=CORREL(range1,range2), where
where range1
range1 and
and range2
range2 contain
contain
the two matched sets of numbers.
the two matched sets of numbers.
Tryit!
Try it! The
The data
datato
to the
theright
right represent
represent monthly
monthlysalessales of
ofthree
three products.
products. Calculate
Calculate
theindicated
the indicated correlations
correlations in
in column
column Q.
Q. (Scroll
(Scroll to
to the
the right
rightfor
for the
theanswers.)
answers.)

There isis aasimilar


There similar function
functionCOVAR
COVAR for
for calculating
calculating covariances.
covariances. AA covariance
covariance isis aa
correlationmultiplied
correlation multiplied by
bythe
theproduct
product of of the
thetwo
twovariables'
variables' standard
standard deviations.
deviations.
Becauseaa covarance
Because covaranceisis affected
affected strongly
stronglyby bythe
theunits
units the
thevariables
variables are
are measured
measured
in, it is not as easy to interpret as a correlation.
in, it is not as easy to interpret as a correlation.
Month Sales1 Sales2 Sales3 Correlations
Jan-03 800 1750 640 Sales1 vs Sales2
Feb-03 1360 2970 280 Sales1 vs Sales3
Mar-03 1150 2370 230 Sales2 vs Sales3
Apr-03 940 2010 410
May-03 740 1690 290
Jun-03 1090 2590 460
Jul-03 780 1640 760
Aug-03 910 2100 840
Sep-03 990 1620 760
Oct-03 800 1790 710
Nov-03 1200 2320 690
Dec-03 1150 2090 640
Jan-04 880 2170 530
Feb-04 870 1640 640
Mar-04 870 1980 560
Apr-04 760 1360 980
May-04 1010 2110 880
Jun-04 820 1740 570
Jul-04 1140 2040 650
Aug-04 730 1940 600
Sep-04 1150 2000 540
Oct-04 690 890 1130
Nov-04 1210 2480 600
Dec-04 1080 2050 660
Jan-05 1420 2840 330
Feb-05 1230 2490 710
Mar-05 1170 2330 610
Apr-05 1140 2540 840
May-05 560 1750 1010
Jun-05 910 2490 950
Jul-05 1260 2930 150
Aug-05 1050 2500 390
Sep-05 1020 2240 440
Oct-05 760 1630 420
Nov-05 710 1380 880
Dec-05 1000 2000 660
Jan-06 940 2200 630
Feb-06 1270 2510 510
Mar-06 1370 2610 560
Apr-06 1050 2180 620
May-06 1110 2590 470
Jun-06 1170 2160 580
Jul-06 990 2020 480
Aug-06 1040 1870 300
Sep-06 1350 2590 540
Oct-06 820 1440 520
Nov-06 860 1870 620
Dec-06 1190 2640 460
Jan-07 910 1980 590
Feb-07 950 2290 510
Mar-07 820 1850 550
Apr-07 770 1710 610
May-07 810 1480 720
Jun-07 1370 2820 770
Jul-07 940 2360 540
Aug-07 1020 1940 420
Sep-07 930 1900 800
Oct-07 1110 2520 660
Nov-07 1230 2320 610
Dec-07 1080 2240 990
Jan-08 890 1840 530
Feb-08 970 1940 520
Mar-08 920 2510 480
Apr-08 1000 2360 370
May-08 1250 2400 380
Jun-08 1280 2490 640
Jul-08 790 1760 450
Aug-08 940 2000 290
Sep-08 1140 2570 460
Oct-08 1020 2760 370
Nov-08 1060 1680 560
Dec-08 1130 2000 60
Jan-09 1050 2270 710
Feb-09 1380 2350 660
Mar-09 770 1410 800
Apr-09 860 2410 360
May-09 1130 1980 700
Jun-09 1350 2960 300
Jul-09 920 2320 380
Sales1 vs Sales2 0.776112
Sales1 vs Sales3 -0.31274
Sales2 vs Sales3 -0.41242
RANK Function
RANK Function

Suppose you
Suppose you want
wanttoto rank
rank aa set
set of
of values
values from
from 11 to
to N,
N, where
where NN isis the
the number
number of
of
values. You can do this with Excel's RANK function. You can rank
values. You can do this with Excel's RANK function. You can rank them in them in
ascendingor
ascending or descending
descending order.
order.

To use
To use the
theRANK
RANK function:
function:

Enter the
Enter theformula
formula =RANK(value,datarange,
=RANK(value,datarange, order), order), where
where value
value isis aa single
singlevalue
value
in the
in the datarange,
datarange, and
and order
order isis an
an optional
optional argument.
argument. IfIf order
order isis00 (or
(or missing),
missing),
rank 11corresponds
rank corresponds to
to the
the largest
largestvalue
value and
and rank
rank NN to
to the
the smallest;
smallest; ifif order
order isis 11(or
(or
any other nonzero value), rank 1 corresponds to the smallest value
any other nonzero value), rank 1 corresponds to the smallest value and rank N to and rank N to
thelargest.
the largest.

Typically, you
Typically, you start
startwith
with aa data
data set
setininaa column.
column. Then
Thenyou
youuse
use the
the RANK
RANK function
function
to rank the first value and copy it down (with datarange absolute)
to rank the first value and copy it down (with datarange absolute) to rank all to rank all of
of
theothers.
the others. IfIf two
two or
or more
more values
values are
are tied,
tied, they
theyshare
shareaa rank.
rank.

Tryit!
Try it! Rank
Rank the
thevalues
values in in column
column KK from
fromlargest
largestto
to smallest
smallest in
in column
column L.L. Then
Then
rank them from smallest to largest in column M. How does RANK
rank them from smallest to largest in column M. How does RANK deal with the deal with the
tied 55s?
tied 55s? (Scroll
(Scroll to
to the
the right
right for
for answers.)
answers.)

LARGE, SMALL
LARGE, SMALL Functions
Functions

TheLARGE
The LARGE and
and SMALL
SMALL functions
functions are
areless
less well-known
well-knownExcelExcel functions,
functions, but
but they
theyare
are
occasionally very
occasionally veryuseful.
useful.Suppose
Suppose you
you have
have aadata
data set
set with
with 250
250 values
values and
and you
you
want the
want the 10
10largest
largest values.
values. Then
Then you
you can
can find
find these
these with
with the
theLARGE
LARGE function,
function,
using arguments 1 through 10. Similarly, you can use the SMALL
using arguments 1 through 10. Similarly, you can use the SMALL function tofunction to find
find
the10
the 10 smallest
smallest values.
values.

To use
To use the
theLARGE
LARGE function:
function:

Enter the
Enter theformula
formula =LARGE(datarange,k),
=LARGE(datarange,k), wherewhere kk isisany
anyinteger
integer from
from11 to
tothe
the
number of
number of data
datavalues.
values.This
This returns
returns the
the kth
kth largest
largest value.
value.

To use
To use the
theSMALL
SMALL function:
function:

Enter the
Enter theformula
formula =SMALL(datarange,k),
=SMALL(datarange,k), wherewhere kk isis any
anyinteger
integer from
from 11 to
to the
the
number of
number of data
datavalues.
values.This
This returns
returns the
the kth
kth smallest
smallestvalue.
value.

Typically, you
Typically, you would
would enter
enter aa sequence
sequence of of values
values of
of kkin
insome
some column,
column, enter
enter the
the
LARGE or
LARGE or SMALL
SMALL formula
formula for
for the
thefirst
firstof
of them,
them, and
andthen
thencopy
copy down.
down.
Tryit!
Try it! For
For the
thedata
data set
setinincolumn
column K,
K, find
find the
the 10
10largest
largest values
values and
and 10 10 smallest
smallest
values in
values incolumns
columns M M and
and N.N.Use
Usecell
cell references
references toto the
the values
values of
of kk in
in column
column L.L.
(Scroll to
(Scroll to the
theright
right for
for the
the answers.)
answers.)
Tryit!
Try it! For
For the
thedata
data set
setinincolumn
column K,K, find
find the
the 10
10largest
largest values
values and
and 10
10 smallest
smallest
values in columns M and N. Use cell references to the values of k in column L.L.
values in columns M and N. Use cell references to the values of k in column
(Scroll to
(Scroll to the
theright
right for
for the
the answers.)
answers.)
Rank 1 largest Rank 1 smallest
55
66
76
34
55
68
75
44
38
58

Largest Smallest
679.02 1
1208.42 2
1635.72 3
729.63 4
1036.08 5
716.62 6
972.92 7
1175.68 8
1271.38 9
1048.93 10
718.89
1282.89
960.55
1356.75
1257.66
902.38
1648.23
1111.56
750.54
1001.74
742.81
707.50
1080.94
1290.85
1115.66
1005.36
1243.57
1454.84
1491.96
991.85
1345.71
1098.38
584.24
1209.50
1416.73
530.54
1171.91
1354.49
989.32
788.77
1264.69
1594.35
1274.46
1023.20
1377.79
1090.11
963.47
623.22
591.33
1060.24
669.80
1260.54
1019.52
819.22
602.14
714.58
996.73
698.22
1116.06
851.37
1223.55
963.66
1114.35
1473.56
755.30
833.30
670.82
859.38
1109.96
1614.91
1035.87
927.74
681.50
953.19
1296.71
379.17
773.67
1235.87
1442.20
1332.61
1314.41
1102.07
894.25
949.84
899.89
842.80
737.26
853.25
1699.23
1084.52
753.02
1004.51
550.14
995.72
1284.55
1217.77
1527.33
937.32
523.64
672.17
1131.39
1283.45
822.97
1364.57
512.38
774.36
1105.61
946.32
730.95
759.13
1119.85
1139.42
1090.73
1446.34
866.76
800.82
1290.49
1477.84
977.47
1101.76
1101.66
1071.95
846.98
1222.82
1277.73
1129.76
1320.94
762.96
1145.85
985.63
664.06
808.46
808.69
1433.58
933.24
1059.90
1172.61
1334.85
752.82
1025.82
798.93
590.03
1362.43
581.92
921.59
1166.95
690.62
1472.74
931.17
1525.45
323.69
1388.36
668.07
1377.30
1374.89
968.95
637.91
592.42
1202.37
1188.52
1031.24
1004.71
1451.57
972.33
1172.22
828.66
914.55
543.38
489.87
988.93
1331.98
1211.72
999.51
963.75
1188.93
517.26
1234.76
953.21
1384.28
1059.93
1041.80
964.87
488.53
1398.93
1046.12
913.83
485.68
1335.03
1373.34
1208.25
1100.58
1051.50
1092.98
1166.45
941.87
1053.52
1095.11
1847.97
546.79
843.64
1306.94
1120.74
1289.04
1192.82
1132.86
1597.10
1078.35
1528.90
972.01
1206.63
1202.84
704.03
962.18
1252.00
1196.82
1279.00
757.50
846.49
855.45
561.13
1300.36
901.77
1015.09
1096.84
644.72
1372.65
579.08
647.23
478.23
1151.76
961.65
1241.79
1076.72
774.44
1149.76
846.46
927.77
1337.16
790.40
807.10
1201.21
1330.02
1100.30
1317.75
1080.59
1400.72
865.18
1383.26
997.08
380.33
6 4
4 7
1 10
10 1
6 4
3 8
2 9
8 3
9 2
5 6

1847.97 323.69
1699.23 379.17
1648.23 380.33
1635.72 478.23
1614.91 485.68
1597.1 488.53
1594.35 489.87
1528.9 512.38
1527.33 517.26
1525.45 523.64
Background on
Background on Financial
FinancialFunctions
Functions

Excel has
Excel hasaa wide
wide assortment
assortment of of financial
financial functions
functions that
that are
are used
used byby thousands
thousands ofof
financial analysts every day. Only a few of the most common
financial analysts every day. Only a few of the most common of these are of these are
discussed here,
discussed here, but
butifif you
youare
areaa financial
financial analyst,
analyst, you
you will
will undoubtedly
undoubtedly want wantto
to
becomefamiliar
become familiar with
withthetheothers.
others. The
The best
best way
way to
to learn
learn isis to
toclick
click the
the Financial
Financial
category on
category onthe
the Formulas
Formulas ribbon.
ribbon.
PMT (Payment)
PMT (Payment) Function
Function

ThePMT
The PMT function
function isis usually
usually used
used to to find
find the
the monthly
monthlypayment
payment for for aa car
car loan
loan oror aa
home mortgage loan. The inputs are typically an annual interest
home mortgage loan. The inputs are typically an annual interest rate, a term rate, a term
(number of
(number of months
months financed),
financed), and
and thethe amount
amount borrowed
borrowed (the
(theprincipal).
principal). TheThePMTPMT
function finds
function finds the
the amount
amountyou you have
haveto to pay
payeach
each month
month ofof the
theterm.
term.PartPart of
of this
this
paymentisisprincipal
payment principal and
and part
part isis interest.
interest. AtAtthe
the end
end of
of the
theterm,
term, you
youwill
will have
havepaidpaid
just enough to pay off the entire
just enough to pay off the entire loan. loan.

To use
To use the
thePMT
PMT function:
function:

Enter the
Enter theformula
formula =PMT(interestrate,term,principal).
=PMT(interestrate,term,principal). For For technical
technical reasons,
reasons, ifif you
you
want PMT
want PMT toto return
return aa positive
positive value,
value, you
youshould
should enter
enter the
theprincipal
principal as
as aa negative
negative
number (because
number (because itit isis aacash
cash outflow,
outflow, not
notaa cash
cash inflow).
inflow).The
Theinterest
interest rate
rateargument
argument
should be
should bethe
the monthly
monthlyrate rate(assuming
(assuming you
you are
are paying
payingmonthly),
monthly), which
whichisisthethe annual
annual
rate divided by
rate divided by 12.12.

Tryit!
Try it! Suppose
Suppose you
you take
take out
outaa $30,000
$30,000 loanloan for
for aanew
new car
car when
when the theannual
annual interest
interest
rate isis 4.75%
rate 4.75% and
and the
the term
termof of the
the loan
loan isis 36
36 months.
months. Calculate
Calculate your
your monthly
monthly
paymentin
payment inthe
theblue
blue cell
cell to
to the
theright.
right. Then
Then use useaa data
data table
table to
to see
see how
how your
your
monthlypayment
monthly payment varies
varies for
for terms
terms ofof24,
24, 36,36, 48,
48, or
or 60
60months.
months. (Scroll
(Scroll to
to the
theright
right to
to
see the
see the answers.
answers. The
TheData
DataTable
Table worksheets
worksheets in inthis
this tutorial
tutorial explain
explaindata
data tables.)
tables.)
Principal $30,000 Data table for payment versus term
Annual interest 4.75%
Term 36
Payment
Term Payment
$895.76
24
36
48
60
NPV(Net
NPV (Net Present
Present Value)
Value) Function
Function

Muchof
Much of the
the theory
theory of
of finance
finance isis about
about the thetime
time value
valueof of money.
money.Basically,
Basically, aadollar
dollar
earned in the future is less valuable than a dollar earned
earned in the future is less valuable than a dollar earned today because the today because the
dollar earned
dollar earnedtodaytodaycan
can earn
earninterest.
interest. To To account
account forfor this,
this, future
future cash
cash inflows
inflows or
or
outflowsare
outflows are discounted
discounted to to get
get their
their present
present valuesvalues now.
now. Given
Given aa future
futurestream
stream of
of
cash inflows
cash inflows and/or
and/or outflows,
outflows, thethe sum
sumof of all
all of
oftheir
their present
present values
values isis called
called the
the
net present
net presentvalue,
value, abbreviated
abbreviated NPV. NPV. IfIf this
this stream
streamisis incurred
incurredat atregular
regular time
time
intervalsatthe
intervalsat the end
end of
of each
each year,
year, sayyou
sayyou can can use
useExcels
Excels handy
handy NPV
NPV function
function
to calculate
to calculatethethe NPV
NPV of
of the
the stream.
stream.

To use
To use the
theNPV
NPV function:
function:

Enter the
Enter theformula
formula =NPV(rate,cashstream).
=NPV(rate,cashstream).Here, Here, rate
rate isis the
the discount
discount rate,
rate, which
which
isis essentially
essentiallythe
the rate
ratethe
the company
company believes
believesititcan
can earn
earn on on its
its money,
money, and
and
cashstream isis aa stream
cashstream streamof of cash
cash inflows
inflows or
or outflows
outflows that
that occur
occur atat the
the ends
ends of
of
successiveyears,
successive years, starting
startingatat the
the end
end of
of year
year 1.
1.

Notethat
Note that ifif there
there isis aacash
cashinflow
inflow or
or outflow
outflow right
right away,
away, at
atthe
the beginning
beginning ofof year
year
1, it should be entered outside the NPV function. The reason is that
1, it should be entered outside the NPV function. The reason is that it doesnt it doesnt
need to
need to be
be discounted.
discounted.

Tryit!
Try it! Assume
Assume aacompany
company pays pays $100,000
$100,000 at atthe
the beginning
beginning ofof year
year 11to
to get
get into
into an
an
investment. It then receives the cash inflows at the ends of years
investment. It then receives the cash inflows at the ends of years 1 through 5 1 through 5
shown to
shown tothe
the right.
right.What
What isis the
theNPV
NPV ofof this
this investment
investment (inflows
(inflows minus
minus outflows)
outflows)
with aa 12%
with 12% discount
discount rate?
rate? Does
Does the
theNPV
NPV increase
increaseor or decrease
decreaseas as the
the discount
discount rate
rate
increases? (Scroll
increases? (Scroll to
to the
the right
rightto
to see
seethe
the answer.)
answer.)

XNPV Function
XNPV Function

IfIf aa company
company incurs
incurs cashcash inflows
inflows or
or outflows
outflows atat irregular
irregular times,
times, such
such as
asJanuary
January
15, then
15, then May
May30, 30, thenthen July
July 1,
1, and
and so so on,
on, the
theNPV
NPV function
functioncannot
cannot be
beused.
used.You
You
could go back to your finance book to see how to
could go back to your finance book to see how to discount future paymentsdiscount future payments
directly, but
directly, but itit isis easier
easier to
to use
usethe
the little-known
little-knownXNPVXNPV function.
function.(Before
(Before Excel
Excel 2007,
2007,
this function
this functionwaswasactually
actually part
part of
of the
theAnalysis
Analysis ToolPak
ToolPak add-in
add-inthat
that ships
shipswith
with
Excel. Since
Excel. Since Excel
Excel 2007, 2007, itithas
has been
been partpartof
of the
the regular
regular financial
financial functions
functions group.)
group.)

To use
To use the
theXNPV
XNPV function:
function:

Enter the
Enter theformula
formula =XNPV(discountrate,cashvalues,dates),
=XNPV(discountrate,cashvalues,dates), where where discountrate
discountrate isis
the same as with NPV, cashvalues is a stream of cash inflows or outflows,
the same as with NPV, cashvalues is a stream of cash inflows or outflows, and and
dates isis aa stream
dates stream of
of the
the dates
dateswhen
whenthey
theyare
are incurred.
incurred.

Typically, the
Typically, the first
first cash
cash value
value will
will be
be an
an outflow
outflow and
and the
the rest
rest will
will be
be inflows.
inflows. In
In this
this
case, the initial outflow (investment) should be included in the XNPV
case, the initial outflow (investment) should be included in the XNPV function, function,
andthe
and the NPV
NPV will
will be
be discounted
discounted back
back to
tothe
the date
dateof
of this
thisinitial
initial payment.
payment. This
This
paymentshould
payment should be beentered
enteredas as aanegative
negative number.
number.

Tryit!
Try it! Find
Findthethe net
netpresent
present value
value of
of the
the stream
streamof
of cash
cash inflows
inflowsshown
shown to to the
the right,
right,
where the
where the first
first isis really
reallyaa payment
paymentat atthe
the beginning
beginning of
of 2013.
2013. (Scroll
(Scroll to
tothe
the right
right to
to
see the
see the answer.)
answer.)
dates is a stream of the dates when they are incurred.
Typically, the
Typically, the first
first cash
cash value
value will
will be
be an
an outflow
outflow and
and the
the rest
rest will
will be
be inflows.
inflows. In
In this
this
case, the
case, the initial
initial outflow
outflow (investment)
(investment) should
should be
be included
included inin the
the XNPV
XNPV function,
function,
andthe
and the NPV
NPV will
will be
be discounted
discounted back
back to
tothe
the date
dateofof this
thisinitial
initial payment.
payment. This
This
paymentshould
payment should be beentered
enteredas as aanegative
negative number.
number.

Tryit!
Try it! Find
Findthe
the net
netpresent
present value
value of
of the
the stream
streamof
of cash
cash inflows
inflowsshown
shown to to the
the right,
right,
where the first is really a payment at the beginning of 2013. (Scroll to the
where the first is really a payment at the beginning of 2013. (Scroll to the right toright to
see the
see the answer.)
answer.)
Discount rate 12%
Initial payment $100,000

Cash inflows at ends of years


Year 1 2 3 4 5
Inflow $20,000 $35,000 $50,000 $45,000 $35,000

NPV

Discount rate 12%


Stream of cash flows
Date 1-Jan-13 25-May-13 15-Sep-13 15-Jan-14 30-Jun-14
Cash $85,000 $22,500 $31,000 $65,500 $55,000

NPV
NPV $29,806
NPV $69,805
IRR (Internal
IRR (Internal Rate
Rate of
of Return)
Return) Function
Function

Companies often
Companies often have
haveinvestment
investmentopportunities
opportunities wherewhere they
they pay
pay initially
initiallyand
andthen
then
get returns in the future. It is easy to show that the NPV of
get returns in the future. It is easy to show that the NPV of such an investment such an investment
decreases as
decreases as the
the discount
discount raterate increases.
increases. InIn fact,
fact, for
for large
large enough
enoughdiscount
discountrates,
rates,
theNPV
the NPV will
will typically
typically become
becomenegative,
negative, meaning
meaning that that the
the future
futurereturns
returns are
arenot
not
enough to
enough to offset
offset the
the initial
initial cost.
cost. The
Thediscount
discount rate
rate atat which
which NPV
NPV changes
changes from
from
positiveto
positive to negative
negativeisiscalled
calledthe the internal
internal rate
rate of
of return,
return, oror IRR.
IRR. Specifically,
Specifically, the
the IRR
IRR
isis the
the discount
discountraterate at
at which
which NPVNPV equals
equals 0.
0.

Companies are
Companies are interested
interestedin inIRR
IRRfor
for the
the following
following reason.
reason.Typically,
Typically, they
they have
haveaa
"hurdle rate" that they use to discount potential investments.
"hurdle rate" that they use to discount potential investments. If the NPV of If the NPV ofan an
investment isis positive,
investment positive, discounted
discountedat atthe
the hurdle
hurdle rate,
rate, itit isis worth
worthpursuing.
pursuing. IfIf itit isis
negative, ititisisnot
negative, not worth
worth pursuing.
pursuing. Stated
Statedequivalently,
equivalently, the the investment
investment isis worth
worth
pursuing only
pursuing only ifif its
its IRR
IRR isis greater
greater than
thanthethe companys
companys hurdle
hurdle rate. rate.
Fortunately, Excel
Fortunately, Excel has
hasanan IRR
IRR function
function that
thatcalculates
calculatesan an investments
investments IRR.
IRR.
Otherwise, this
Otherwise, this would
would be
beaa difficult
difficult calculation.
calculation.As As with
withthe
the NPV
NPV function,
function, the
the
investment should
investment should be
be structured
structuredso so that
that there
there isis an
aninitial
initial cash
cashpayment
payment at at the
the
beginning of year 1 and then regular cash returns at the ends of years
beginning of year 1 and then regular cash returns at the ends of years 1, 2, and 1, 2, and so
so
on.
on.
To use
To use the
the IRR
IRR function:
function:

Enter the
Enter the formula
formula =IRR(cashstream,rateguess),
=IRR(cashstream,rateguess), where where cashstream
cashstream isis aastream
stream of
of
cash flows,
cash flows, where
wherethe
thefirst
first(the
(the initial
initial payment)
payment) should
should be
be negative,
negative, and
and rateguess
rateguess
isis an
aninitial
initial guess
guess for
for the
the IRR.
IRR.

This seems
This seems strange.
strange. Why
Why should
should you
you have
haveto to guess
guess at
at the
the answer?
answer? ItIt isis because
because
Excel calculates
Excel calculates the
theIRR
IRRiteratively,
iteratively, starting
startingwith
withyour
your guess.
guess. Your
Your actual
actual guess
guess
shouldnt make
shouldnt make any
any difference
difference inin the
the final
final answer
answer except
except inin unusual
unusual cases.
cases.

Try it!
Try it! Find
Findthe
theIRRIRRfor
for the
theinvestment
investmenttoto the
theright,
right, using
using anan initial
initial guess
guess of
of 15%.
15%.
What does
What does this
this IRR
IRR say
say about
aboutthe
the attractiveness
attractiveness ofof the
the investment?
investment? (Scroll
(Scroll to
to the
the
right to
right to see
see the
the answer.)
answer.)

The previous
The previous worksheet
worksheetdescribed
describedan an XNPV
XNPV function
function for
for cash
cashflows
flows that
that don't
don't
occur on
occur on regularly
regularly spaced
spaced dates.
dates. There
There isis aa corresponding
correspondingXIRRXIRRfunction.
function. IfIfyou
youare
are
interested, you
interested, you can
can look
look itit up
upin
inonline
onlinehelp.
help.
Cash flows (initial value is a payment)
$100,000 $35,000 $45,000 $40,000 $25,000 $10,000

IRR
IRR 19.81%

The company
The companywillwill find
findthis
this investment
investment
attractive only
attractive only ifif its
its hurdle
hurdle rate
rate isis
below 19.81% (which it probably
below 19.81% (which it probably is). is).
vestment
estment
te
e isis
ably is).
bly is).
Background on
Background on Reference
Reference Functions
Functions

OneExcel
One Excel expert
expert made
made the the claim
claim that
that the
theVLOOKUP
VLOOKUPfunction,
function, discussed
discussed in in aa
previous worksheet, is the most useful Excel function of all. Whether
previous worksheet, is the most useful Excel function of all. Whether or not you or not you
believethis
believe this claim,
claim, the
the VLOOKUP
VLOOKUP and and HLOOKUP
HLOOKUP functions
functionsare are just
just two
twoofof some
some
very useful
very useful lookup
lookup and
and reference
reference functions
functions inin Excels
Excelsarsenal.
arsenal. On On the
theFormulas
Formulas
ribbon, you
ribbon, youwill
will see
see aaLookup
Lookup and and Reference
Reference category
categoryof of functions
functionsthat thatincludes
includes
VLOOKUP, HLOOKUP, and several others. A few of the others
VLOOKUP, HLOOKUP, and several others. A few of the others here, specifically here, specifically
INDEX, MATCH,
INDEX, MATCH, OFFSET,
OFFSET, and andINDIRECT,
INDIRECT, are
are discussed
discussed here.
here.Although
Although they they are
are
arguablynot
arguably not as
as useful
useful asas VLOOKUP,
VLOOKUP, they
they definitely
definitely come
come in in handy
handyin incertain
certain
situations.
situations.
INDEX Function
INDEX Function

TheINDEX
The INDEX function
function isis useful
useful for
for finding
findingthe
thevalue
value in
in aa particular
particular cell
cell of
of aa
rectangular range. You access this value by the indexes of the
rectangular range. You access this value by the indexes of the cell you want.cell you want.
Specifically, you
Specifically, you specify
specifyaa rowrow index
index and
and aacolumn
columnindex.
index. For
For example,
example, ifif the
the range
range
has10
has 10 rows
rowsand
and20
20 columns,
columns, the the index
index 4,8
4,8 indicates
indicatesthethe 4th
4th row
row and
and8th
8th column
column
of the
of the range.
range.

To use
To use the
theINDEX
INDEX function:
function:

Enter the
Enter theformula
formula =INDEX(range,r_index,c_index),
=INDEX(range,r_index,c_index), where
where r_index
r_index isis an
an integer
integer
(for row) and c_index is an integer (for column).
(for row) and c_index is an integer (for column).
For example,
For example, thethe formula
formula =INDEX(D11:F20,4,2)
=INDEX(D11:F20,4,2) refers
refers to
to the
the value
valuein
in cell
cell E14,
E14, the
the
cell in
cell in the
the 4th
4th row
row and
and 2nd
2nd column
column of
of the
the range.
range.

IfIf range
range isis aa single-column
single-columnrange,
range, the
the c_index
c_index argument
argumentcan can be
be omitted.
omitted. In
In that
that
case, =INDEX(range,r_index)
case, =INDEX(range,r_index) returns
returnsthe
the value
value in
in row
row r_index
r_index of
of the
therange.
range.ForFor
example, the
example, the formula
formula =INDEX(A11:A20,3)
=INDEX(A11:A20,3) refers
referstoto the
thevalue
value in
in cell
cell A13,
A13, the
the 3rd
3rd
cell in the
cell in the range.range.

Similarly, ifif range


Similarly, range isis aa single-row
single-row range,
range, only
only c_index
c_index needs
needsto
to be
beincluded.
included. For
For
example, the
example, the formula
formula =INDEX(B10:E10,3)
=INDEX(B10:E10,3) refers
refers to
to the
the value
value in
incell
cell D10,
D10, the
the 3rd
3rd
cell in the range.
cell in the range.
Tryit!
Try it! Find
Findthethe unit
unitshipping
shipping cost
cost from
fromPlant2
Plant2to to City3
City3 with
withaa formula
formula in in the
the blue
blue
cell to
cell to the
the right.
right. Then
Then enter
enter aa formula
formulain inthe
theredred cell
cell that
thatfinds
finds the
theunit
unit shipping
shipping
costfrom
cost from the
theplant
plantto to the
the city
cityspecified
specifiedin in the
the two
two cells
cells above.
above.This
This formula
formula
should respond
should respond appropriately
appropriately to to whatever
whateverplant plant and
and city
cityindexes
indexesare
are entered
entered inin
thesetwo
these two cells.
cells. (Scroll
(Scroll to
tothe
the right
right for
for the
the answers.)
answers.)
Unit shipping costs City1 City2 City3
Plant1 1.25 1.35 1.55
Plant2 1.15 1.45 1.25
Plant3 1.35 1.45 1.15

Unit shipping from Plant2 to City3

Plant 1
City 2
Unit shipping cost
Unit shipping from Plant2 to City3 1.25

Unit shipping cost 1.35


MATCH Function
MATCH Function

TheMATCH
The MATCH function
function isis handy
handy forfor finding
finding aa cell
cell in
in aarange
rangethat
thatmatches
matches aa given
given
value. It is often used in the following situation. Suppose you
value. It is often used in the following situation. Suppose you have decision have decision
variable such
variable such as as order
order quantity
quantitythatthatneeds
needsto to be
bechosen
chosento to maximize
maximize profit.
profit. You
You
enter some
enter some formulas
formulas that
thatlink
link order
order quantity
quantity totoprofit.
profit. Then
Thenyouyou create
createaa data
data
table that
table that finds
finds the
the profit
profitfor
for aanumber
number of of possible
possibleorderorder quantities.
quantities. The
The MATCH
MATCH
function lets you locate the cell in the data table with the
function lets you locate the cell in the data table with the largest profit.largest profit.

To use
To use the
theMATCH
MATCH function:
function:

Enter the
Enter theformula
formula =MATCH(value,range,0).
=MATCH(value,range,0). This Thisreturns
returns the
the index
index of
of the
the cell
cell in
in
range that
range that matches
matches value.
value. For
For example,
example, ifif the
thematch
matchoccurs
occursin inthe
the 3rd
3rd cell
cell of
of the
the
range, this
range, this returns
returns 3.3.The
The last
last argument,
argument, 0, 0, indicates
indicatesthat
thatyou
youwant
want an
an exact
exact
match. IfIf there
match. there isis no
no exact
exactmatch,
match, the
the formula
formula returns
returnsan
an error.
error.(Actually,
(Actually, the
the
MATCH function can also look for an inexact match by using
MATCH function can also look for an inexact match by using a +1 or -1 for thea +1 or -1 for the
thirdargument.
third argument. You Youcan
canlook
look up
up the
the details
detailsin in online
online help.)
help.)

Thetop
The top example
exampleto to the
theright
right indicates
indicates howhowMATCH
MATCH can can bebe used
used in in conjunction
conjunction
with INDEX. Imagine that a profit model has led to the
with INDEX. Imagine that a profit model has led to the table shown, wheretable shown, where each
each
order quantity
order quantitylisted
listed leads
leads to
to the
the corresponding
corresponding profit.
profit. For
For this
thissmall
small example,
example, itit
isis obvious
obvious that
that the
thelargest
largest profit
profit isis $5,640,
$5,640, which
which corresponds
correspondsto to an
anorder
order
quantity of
quantity of300.
300.However,
However, ififinputs
inputs(not (notshown
shown here)
here) that
thatdrive
drive the
the profit
profitmodel
model
change, the best order quantity and the corresponding profit
change, the best order quantity and the corresponding profit could change. You could change. You
want formulas
want formulas in
inthe
the blue
blueand
and red
red cells
cellsto
to the
the right
right to
to show
show the thebest
bestprofit
profit and
and
best order
best order quantity
quantityregardless
regardless of of where
where they
they appear
appear in in the
the table.
table.

Theformula
The formulain in the
thered
redcell
cell isis =INDEX(K6:K10,MATCH(L12,L6:L10,0)).
=INDEX(K6:K10,MATCH(L12,L6:L10,0)).The Thewhole
whole
purposeof
purpose of the
theMATCH
MATCH function
functionhere hereisisto
to provide
provide the
therowrow index
indexforfor the
the INDEX
INDEX
function. That
function. Thatis,
is, you
you know
know the the best
best order
order quantity
quantityisis one
one of
of the
the values
values inin the
the
range K6:K10,
range K6:K10, andand you
you need
need to to know
know which
which one.
one.So
So you
you find
findaa match
match forfor the
the
maximum profit
maximum profitto to the
theprofits
profits in inL6:L10.
L6:L10. InInthis
thiscase,
case, the
the maximum
maximum isis thethe 3rd
3rd
profit, so
profit, so the
the formula
formula isis equivalent
equivalent to to =INDEX(K6:K10,3).
=INDEX(K6:K10,3).

Tryit!
Try it! The
The table
table totothe
the right
rightshows
shows the
the profit
profit for
for each
each order
order quantity
quantity (along
(along the
the
side) and each unit stockout cost (along the top). Enter copyable formulas
side) and each unit stockout cost (along the top). Enter copyable formulas in the in the
green range
green range to
to find
find the
the best
best order
order quantity
quantity for
for each
each unit
unit stockout
stockout cost.
cost. (Scroll
(Scroll to
to
theright
the rightto
to see
seethetheanswer.)
answer.)
Table of profit versus order quantity
Order quantity Profit
200 $5,325
250 $5,430
300 $5,640
350 $5,565
400 $5,235

Best profit $5,640


Best order quantity 300

Profit for various order quantities (column L) and unit stockout costs (row 32)
$2 $3 $4 $5
200 $5,235 $5,175 $5,025 $4,935
250 $5,465 $5,285 $5,190 $5,085
300 $5,355 $5,325 $5,265 $5,100
350 $5,215 $5,195 $5,130 $5,125
400 $5,145 $5,085 $5,015 $5,005

Best order quantities


Best order quantities 250
300 300 350
Syntax of
Syntax of OFFSET
OFFSET Function
Function

TheOFFSET
The OFFSETfunction
function allows
allows you
you toto reference
referenceaa range
range (or
(or single
single cell)
cell) relative
relative to
to
another cell. It is hard to appreciate this function unless you see some
another cell. It is hard to appreciate this function unless you see some examples, examples,
so some
so sometypical
typical examples
examples are
areillustrated
illustrated below.
below.

To use
To use the
theOFFSET
OFFSET function:
function:

Enter the
Enter theformula
formula =OFFSET(cell,r_offset,c_offset,height,width).
=OFFSET(cell,r_offset,c_offset,height,width). Here, Here, r_offset
r_offset
and c_offset
and c_offset areare integers
integers that
that can
can be be positive,
positive, negative,
negative, oror zero,
zero, and
and height
height andand
width are
width are optional
optional positive
positiveintegers.
integers.IfIf either
either height
height and
and width
width areare missing,
missing, theythey
default to
default to 1.
1.This
This formula
formula returns
returns aa reference
reference toto aa range
range that
that has
has as
asmany
many rows
rows asas
height and
height andas as many
many columns
columns as as width.
width. To Tofind
findits
its upper
upper left
left cell,
cell, start
start at
at cell,
cell, move
move
r_offset rows
r_offset rowsdown
down (if(if positive)
positive) oror upup (if
(if negative),
negative), and
and move
move c_offset
c_offset columns
columns to to
theright
the right(if
(if positive)
positive) or
or the
theleft
left (if
(if negative).
negative).
For example
For example the the formula
formula =OFFSET(A1,2,3,4,1)
=OFFSET(A1,2,3,4,1) returns
returns aareference
referenceto to the
the range
range
D3:D6. ItItisis aa range
D3:D6. range with
with44 rows
rows and
and 11column,
column, and
and its
its upper
upper left
left cell,
cell, D3,
D3, isis offset
offset
from cell
from cell A1
A1 by bygoing
going22 rows
rows down
down and
and 33 columns
columns to
to the
the right.
right.

As another
As another example,
example, the
theformula
formula =OFFSET(F4,0,-3)
=OFFSET(F4,0,-3) refers
refers to toaa single
single cell
cell (because
(because
thelast
the last two
two arguments
arguments are
are missing),
missing), and
and this
thissingle
single cell
cell isis 33columns
columnsto to the
theleft
left of
of
cell F4,
cell F4, namely,
namely, C4.
C4.

Using the
Using the OFFSET
OFFSET Function
Function for
forDelayed
Delayed Payements
Payements

AA good
goodexample
exampleof of the
the OFFSET
OFFSET function
function appears
appears in in the
the example
example totothe
the right.
right.AA
companysells
company sellsto
to aa retailer,
retailer, and
and the
theretailer
retailer pays
pays aacertain
certain number
number ofofmonths
months
later, as
later, as indicated
indicatedby by the
the payment
payment delay
delay (in
(in months)
months) in in cell
cell L27.
L27. The
The sales
sales occur
occur as
as
indicatedin
indicated inrow
row 30,
30, but
but the
the receipts
receipts from
from the
the retailer
retailer occur
occur two
two months
months later,
later, as
as
indicatedin
indicated inrow
row 31.
31.

Withoutthe
Without the OFFSET
OFFSET function,
function, youyou could
couldsimply
simplyput putlinks
linksin inthe
the Receipts
Receipts row row that
that
point to
point to sales
sales two
two months
months earlier.
earlier. For
For example,
example, the the formula
formula for for receipts
receipts in in
January would
January would be be =M30.
=M30. But But what
whatifif the
theretailer
retailer decides
decidesto to delay
delay payments
paymentsby by
three months
three months instead
insteadof of two?
two? Then
Then you you would
would need need to to fix
fix the
the links
links in
in the
the
Receipts row.
Receipts row.However,
However, aa cleverclever use
use of of OFFSET
OFFSET avoidsavoids this
this updating
updatingof of links.
links. You
You
can use
can use the
the formula
formula =OFFSET(N30,0,-$L$27)
=OFFSET(N30,0,-$L$27) in incell
cell N31
N31 for forJanuary
Januaryand andcopycopy itit
across row
across row 31 31 for
for the
theother
other months.
months. This This formula
formula says says toto start
start in
in the
the December
December
sales cell
sales cell and
andgogo aa certain
certainnumber
number of of cells
cells to
to the
theleft
left (because
(becauseof of the
theminus
minus sign),
sign),
where this number is specified in cell L27. To see how
where this number is specified in cell L27. To see how it works, change the valueit works, change the value
in cell
in cell L27
L27 toto 33or
or 1.1. (If
(If the
the delay
delay isis 3,
3, you
you will
will need
need toto copy
copythe theformula
formulaaheadahead to to
September; ifif itit isis 1,
September; 1, you
you will
will need
need to to copy
copy itit to
to back
backto to November.)
November.)

Tryit!
Try it! Suppose
Suppose that that aamanufacturing
manufacturingcompanycompany buys buys raw
rawmaterials
materialsfrom
from aa
supplier. IfIf the
supplier. thecost
cost in
in any
anymonth
monthisis $x,$x, the
thecompany
companypays pays 40%
40% ofof this
thiscost
cost one
one
monthfrom
month from nownow and
and the
theother
other 60%60% two
two months
months fromfrom now.
now.UseUse the
the OFFSET
OFFSET
function to
function tocalculate
calculatethethepayments
payments made made in in January
January through
throughAugust
August in in the
the green
green
cells to the right, based on the costs through July. These calculated
cells to the right, based on the costs through July. These calculated payments payments
should change
should change automatically
automaticallyifif youyou change
changethe theinputs
inputs in
in the
the blue
blue oror red
red cells
cells
above. For
above. For example,
example, makemake sure
sureyour
your formulas
formulas reactreactcorrectly
correctly ifif you
you enter
enter 22andand33
in the
in thetwo
tworedred cells.
cells.(Scroll
(Scroll to
to the
theright
right to
to see
see thethe answer.)
answer.)
Tryit!
Try it! Suppose
Suppose thatthat aamanufacturing
manufacturingcompanycompany buys buys raw
rawmaterials
materialsfrom
from aa
supplier. If the cost in any month is $x, the company pays
supplier. If the cost in any month is $x, the company pays 40% of this cost 40% of this cost one
one
monthfrom
month from now
now andand the
theother
other 60%60% two
two months
months fromfrom now.
now.UseUse the
the OFFSET
OFFSET
function to
function tocalculate
calculatethethepayments
payments made made in in January
January through
throughAugust
August in in the
the green
green
cells to
cells tothe
the right,
right, based
based ononthethecosts
coststhrough
through July.July.These
These calculated
calculated payments
payments
should change
should change automatically
automaticallyifif youyou change
changethe theinputs
inputs in
in the
the blue
blue oror red
red cells
cells
above. For
above. For example,
example, makemake sure
sureyour
your formulas
formulas reactreactcorrectly
correctly ifif you
you enter
enter 22andand33
in the
in thetwo
tworedred cells.
cells.(Scroll
(Scroll to
to the
theright
right to
to see
see thethe answer.)
answer.)

Creating Dynamic
Creating Dynamic Range
Range Names
Nameswith
withOFFSET
OFFSET

Another great
Another greatuseuse of of the
the OFFSET
OFFSET function
function isis to
to create
create aa dynamic
dynamic range
range name,
name, oneone
thatexpands
that expands or or contracts
contractsdepending
depending on onthe
the number
number of of data
data values
values in in aa range.
range.
Consider the
Consider the example
example to to the
the right,
right, where
where monthly
monthly sales
sales values
values are
are entered
entered in in
column L, and the total of all sales values is calculated in the orange
column L, and the total of all sales values is calculated in the orange cell. Every cell. Every
month, an
month, anextra
extra sales
sales value
value and
and its
its month
month label
label are
are appended
appendedto to the
the list
listinin
columns KK and
columns and L.L. You
You can
canmake
makethetheformula
formulain inthe
theorange
orange cell
cell automatically
automatically
adjust to
adjust to the
the appended
appendedvalues values byby using
using aa dynamic
dynamic range
range name.
name.

To do
To do this,
this, select
select the
the Define
DefineName
Namedropdown
dropdownin in the
theFormulas
Formulas ribbon.
ribbon. In
In the
the
Name box
Name box at
at the
thetop
top ofof the
theresulting
resulting dialog
dialogbox,
box, enter
enter Sales
Sales as
as the
the range
rangename.
name.In
In
the Refers
the Refers ToTo box
box at
at the
the bottom,
bottom, enter
enter the
the formula
formula

=OFFSET($L$57,0,0,COUNTA($L:$L)-COUNTA($L$1:$L$56),1).
=OFFSET($L$57,0,0,COUNTA($L:$L)-COUNTA($L$1:$L$56),1).
(See to
(See to the
the right.)
right.) Then
Then click
click OK.
OK.Finally,
Finally, enter
enter thetheformula
formula =SUM(Sales)
=SUM(Sales) in inthe
the
orange cell. Note that COUNTA($L:$L) refers to the count of all
orange cell. Note that COUNTA($L:$L) refers to the count of all nonblank cells in nonblank cells in
column L,L, and
column and COUNTA($L$1:$L$56)
COUNTA($L$1:$L$56) refers refers toto all
all the
the nonblank
nonblank cells
cellsin
incolumn
columnLL
above the
above the Sales
Sales data.
data. So
Sothe
the difference
difference isisthe
the number
number of of sales
sales values
values inin column
columnL.L.
Therefore, this
Therefore, this OFFSET
OFFSET function
function refers
refers to
to aa range
range that
that starts
starts in
in cell
cell L57
L57 and
and has
has as
as
many rows as there are sales values in column L. To see how
many rows as there are sales values in column L. To see how it adjusts, enter a it adjusts, enter a
sales value
sales value for
for June
June below
below thethe May
May row
row and
and watch
watch howhow the
the total
total changes
changes
automatically.
automatically.
Again, note
Again, note that
that COUNTA($L:$L)
COUNTA($L:$L) counts
counts all all nonblank
nonblank values
values in
in column
columnL,L, sosoifif
there were
there were some
some other
other numbers
numbers down
down belowbelow sales,
sales, they
they would
would mess
mess up
upthethe logic
logic
in the
in the OFFSET
OFFSET function.
function. For
For example,
example, suppose
suppose therethere were
were aa numeric
numeric value
value inin cell
cell
L200. Then
L200. Then the
the fourth
fourth argument
argument ininthe
the OFFSET
OFFSET function
function would
would return
return 6,
6, not
not 5,5, so
so
at that point, the Sales range name would refer to the range L57:L62,
at that point, the Sales range name would refer to the range L57:L62, that is, 6 that is, 6
cells starting
cells starting with
withL57.
L57. The
The moral
moral isis that
that ifif you
you want
want toto use
use dynamic
dynamic range
range names,
names,
you have
you have to
to be
be careful
careful about
about junk
junkin inthe
the affected
affected columns
columns or or rows.
rows.

Try it!
Try it!The
Thedata
data way
wayoutout to
tothe
the right
right has
has sales
salesby
bymonth
monthand andbybysalesperson.
salesperson.YouYou
want to
want to sum
sum sales
sales over
overallall months
months and and salespeople
salespeople in in the
the tan
tan cell.
cell.Create
Createaa
dynamic range
dynamic range name
name thatthat updates
updates when
when newnew months
monthsare are added
addedandand when
when
salesperson columns
salesperson columns are are added
added or or deleted.
deleted. Then
Thenuseuse this
this range
range name
name toto sum
sum
sales in the tan cell. (Note that this example has been placed way
sales in the tan cell. (Note that this example has been placed way out to the right out to the right
sothat
so thatno no "junk"
"junk" from
from the
the previous
previousexamples
examples on on this
this worksheet
worksheet are are above
aboveit.
it. This
This
makes the
makes the dynamic
dynamic range
range formula
formula aa bit
bit easier.)
easier.)
Payment delay 2

Month Oct Nov Dec Jan Feb Mar Apr May Jun
Sales 3200 4600 5500 2500 3300 4200 2900 4500 2750
Receipts 3200 4600 5500 2500 3300 4200 2900

Percent paid 40% when: 1 month from now


60% 2 months from now

Month Oct Nov Dec Jan Feb Mar Apr May Jun
Cost $1,950 $2,900 $4,150 $2,500 $3,350 $2,850 $3,550 $1,850 $4,200
Payment
Month Sales Total $17,030
Jan-11 $2,450
Feb-11 $3,140
Mar-11 $3,250
Apr-11 $4,510
May-11 $3,680
Jul Aug

4500 2750

Jul Aug Jan Feb Mar Apr


$2,300
$3,400 $3,490 $2,840 $3,150
May Jun Jul Aug

$3,130 $2,870 $2,790 $3,440


Total sales $202,900
Smith Jones
Jan-05 $6,700 $7,400
Feb-05 $5,800 $8,900
Mar-05 $5,000 $7,900
Apr-05 $6,700 $5,800
May-05 $9,400 $7,800
Jun-05 $6,200 $5,800
Jul-05 $8,700 $5,300

Answer: Open
Answer: Openthe
the name
name manager
manager andandlook
lookat
a
the definition
the definitionof
of the
theSales1
Sales1 range
range name.
name.
Wilson Donalds
$5,800 $9,000
$5,500 $7,900
$5,900 $8,300
$6,000 $9,700
$6,700 $8,400
$9,400 $8,500
$6,900 $7,500

the name manager


he name manager andandlook
lookat
at
off the
theSales1
Sales1 range
range name.
name.
INDIRECT Function
INDIRECT Function

TheINDIRECT
The INDIRECT function
function isis useful
useful when
when you you have
have named
namedranges
ranges and
and want
want to to refer
refer
to these, via labels, in your formulas. For example, suppose
to these, via labels, in your formulas. For example, suppose you have ranges you have ranges
named Sales1,
named Sales1, Sales2,
Sales2, etc.
etc. Each
Each of
of these
these isis aa long
long column
column of of data.
data. Then
Then suppose
suppose
you have
you havelabels
labels Sales1,
Sales1, Sales2,
Sales2, etc.
etc. in
in some
some other
other cells,
cells, say,
say, G1,
G1, G2,
G2, etc.
etc. IfIf you
you
enter the
enter the formulas
formulas =AVERAGE(INDIRECT(G1)),
=AVERAGE(INDIRECT(G1)), =AVERAGE(INDIRECT(G2)),
=AVERAGE(INDIRECT(G2)), etc. etc. in
in
cells H1, H2, etc., this is the same as entering the formulas =AVERAGE(Sales1),
cells H1, H2, etc., this is the same as entering the formulas =AVERAGE(Sales1),
=AVERAGE(Sales2), etc.
=AVERAGE(Sales2), etc. The
Thename
nameof of the
the function
function implies
implies that
that you
you are
are indirectly
indirectly
referencing the
referencing thenamed
named range
range via
viaaa label
label with
with thisthisrange
rangename.
name.

Tryit!
Try it! The
The data
datain
incolumns
columns L-OL-O have
have been
been range-named
range-namedProduct1
Product1through
through
Product4. Use
Product4. Use the
the AVERAGE,
AVERAGE, STDEV,
STDEV, and
and CORREL
CORREL functions,
functions, along
along with
with the
the
INDIRECT function,
INDIRECT function, toto enter
enter copyable
copyable formulas
formulas in
in the
the blue
blueand
and red
red ranges
ranges below.
below.
(Seeto
(See to the
theright
right for
for the
the answers.)
answers.)
Monthly sales
Month Product1 Product2 Product3 Product4
Jan-09 1043 1047 957 1031
Feb-09 993 832 883 796
Mar-09 968 1114 1206 1048
Apr-09 1461 1487 1495 1519
May-09 1137 1183 1035 1045
Jun-09 1103 999 931 1133
Jul-09 1140 1025 1124 982
Aug-09 772 927 797 922
Sep-09 1195 1297 1231 1230
Oct-09 1140 1358 1267 1253
Nov-09 1236 1120 1107 1275
Dec-09 696 573 513 687
Jan-10 749 581 481 711
Feb-10 984 1005 998 804
Mar-10 1114 933 1084 963
Apr-10 758 832 950 745
May-10 307 418 428 508
Jun-10 1055 807 865 1102
Jul-10 1108 1149 1240 1275
Aug-10 1286 1041 919 968

Averages, standard deviations


Average Stdev
Product1
Product2
Product3
Product4

Correlations
Product1 Product2 Product3 Product4
Product1
Product2
Product3
Product4
Averages, standard deviations
Average Stdev
Product1 1012.25 254.51
Product2 986.40 265.33
Product3 975.55 272.93
Product4 999.85 245.84

Correlations
Product1 Product2 Product3
Product1 1.000 0.855 0.824
Product2 0.855 1.000 0.942
Product3 0.824 0.942 1.000
Product4 0.855 0.891 0.858
Total sales
Product4
0.855
0.891
0.858
1.000
Smith Jones Wilson Donalds
Jan-05 $6,700 $7,400 $5,800 $9,000 Answer: Open
Answer: Open the
the name
name manager
manager and
and
the definition
the definition of
of the
the Sales1
Sales1 range
range nam
nam
Feb-05 $5,800 $8,900 $5,500 $7,900
Mar-05 $5,000 $7,900 $5,900 $8,300
Apr-05 $6,700 $5,800 $6,000 $9,700
May-05 $9,400 $7,800 $6,700 $8,400
Jun-05 $6,200 $5,800 $9,400 $8,500
Jul-05 $8,700 $5,300 $6,900 $7,500
er: Open
er: Open the
thename
name manager
manager and
and look
look at
at
efinition of
efinition of the
the Sales1
Sales1range
rangename.
name.
Powerful Tools
Powerful Tools for
for Analyzing
AnalyzingData
Data

ItItisis not
not really
reallyaccurate
accurate toto call
call Excel
Excel aa statistical
statistical package
package(it(ithas
has nowhere
nowhere near
near the
the
statistical tools of a package such as SPSS or SAS), but it does
statistical tools of a package such as SPSS or SAS), but it does have some very have some very
powerful tools
powerful tools for
for analyzing
analyzingdata.
data.IfIfyou
you plan
plan toto do
do any
anyserious
serious data
data analysis
analysis in
in
Excel, the
Excel, thetools
tools described
described inin this
thissection
section are
are ananabsolute
absolutemust.
must.Yes,
Yes, there
thereare
are
other ways
other ways toto accomplish
accomplishthe the same
same tasks
tasks in
in Excel
Excel without
without these
these tools,
tools, but
butthey
they
are painfully inefficient by comparison.
are painfully inefficient by comparison.
General Information
General Information About
About Data
Data Tables
Tables

Datatables,
Data tables, also
also called
called what-if
what-if tables,
tables, allow
allow you youto
to see
seevery
very quickly
quicklyhow
how one
one oror
more outputs change as one or two key inputs change. This is called
more outputs change as one or two key inputs change. This is called sensitivity sensitivity
analysis, or
analysis, or simply
simply what-if
what-if analysis,
analysis, and
and ititisis aakey
key part
partofof most
most business
businessmodels.
models.

Thereare
There aretwo
two types
types of
of data
datatables:
tables: one-way
one-waytables
tables and
andtwo-way
two-waytables.
tables. AA one-
one-
way table has one input and any number of outputs. A two-way table
way table has one input and any number of outputs. A two-way table has two has two
inputs but
inputs but only
only one
one output.
output. These
Theseare
arediscussed
discussed in
in the
thefollowing
following two
two worksheets.
worksheets.

Business models
Business models are
are all
all about
about what-if
what-if questions.
questions.WhatWhatwould
would happen
happento to profit
profit ifif
our unit cost increased by x%? What would happen to our
our unit cost increased by x%? What would happen to our sales if our sales if our
competitor's production
competitor's production decreased
decreased bybyy%?
y%? AndAnd so
so on.
on.Data
Datatables
tables are
areperfect
perfect for
for
answeringthese
answering thesetypes
types of of questions
questions in
inaa systematic
systematic way,
way, and
and they
theyare
are quite
quite easy
easy
tocreate.
to create. Therefore,
Therefore, itit isis surprising
surprisingthat
that so
so few
fewExcel
Excel users
users are
areaware
aware ofofdata
data
tables. This is a very valuable skill, so make sure you
tables. This is a very valuable skill, so make sure you learn it!learn it!

Recalculation and
Recalculation and Data
Data Tables
Tables

Some data
Some datatables
tables areare very
very long
long(many
(many rows),
rows), and
and each
each value
value might
might require
requirethe
the
recalculation of
recalculation of aa complex
complexbusiness
business model,
model, soso the
therecalculation
recalculation of of the
theentire
entiredata
data
table might
table might take
take aawhile,
while, several
several seconds
seconds oror even
even minutes.
minutes. InIn this
this case,
case, remember
remember
(seethe
(see the Calculation
CalculationOptionsOptionsworksheet
worksheet ininthis
this tutorial)
tutorial) that
thatyou
youcancanselect
selectthe
the
Automatic Except for Data Tables option from the Formulas
Automatic Except for Data Tables option from the Formulas ribbon, as shown to ribbon, as shown to
theright.
the right. In
In this
this case,
case, the
thedata
data tables
tableswon't
won't recalculate
recalculate until
until you
you force
force them
themto to by
by
pressing the
pressing theF9 F9key.
key.
Creating aa One-Way
Creating One-Way Data
Data Table
Table

AA one-way
one-waydata
data table
tablelets
letsyou
you see
see how
how one
oneor
or more
more selected
selected outputs
outputs change
changeas
as aa
single input varies over some range.
single input varies over some range.
To illustrate,
To illustrate, suppose
supposeMr. Mr. Jones
Jonesbuysbuys aa new
new car
car for
for $20,000,
$20,000, makes
makes aa $5,000
$5,000 down
down
payment, and
payment, and finances
finances thethe remaining
remaining amount
amount over
over the
the next
next 36
36months
monthsat at aa6.5%
6.5%
annual interest
annual interestrate.
rate. There
Thereare are at
at least
least two
two outputs
outputs that
that might
mightbebe of
of interest:
interest: the
the
monthlypayment
monthly payment andand the
the total
total interest
interest paid
paidthrough
through the
theduration
durationofof the
the loan.
loan.
These are
These are affected
affected byby the
the four
four inputs:
inputs: price,
price, down
downpayment,
payment,interest
interestrate,
rate, and
and
term.
term.
Letsfirst
Lets first look
look at
at aasimple
simpleone-way
one-way data
datatable,
table, which
whichillustrates
illustrateshow
howaa single
single
output, monthly
output, monthly payment,
payment, varies
varies as
as the
the annual
annual interest
interestrate
rate varies.
varies.This
This isis shown
shown
in the
in thetop
top example
example toto the
the right.
right.
To create
To create the
the table
tablein
incolumns
columns NN and
and OO(which
(which has
has already
already been
been done):
done):

1.Enter
1. Enter aalink
link to
to the
the green
green output
output cell
cell in
inthe
thered
red cell
cell to
to the
theright.
right. Specifically,
Specifically,
because the monthly payment was calculated with the
because the monthly payment was calculated with the PMT function in PMT function in the
thegreen
green
cell, enter
cell, enter the
theformula
formula =L10
=L10 ininthe
thered
red cell.
cell.
2.Enter
2. Enter any
anysequence
sequence of of interest
interestrates
rates inin the
the orange
orange range.
range.
3.Select
3. Select the
theentire
entiretablethe
tabletheboxed-in
boxed-in range.
range.Then
Thenfrom
from the
theData
Data Tools
Tools group
group onon
the Data ribbon, select Data Table from the What-If Analysis
the Data ribbon, select Data Table from the What-If Analysis dropdown (see the dropdown (see the
topscreenshot
top screenshot to to the
theright).
right).
4.Enter
4. Enter L7,
L7, the
the blue
blueinterest
interest rate
ratecell,
cell, as
as the
the column
column input
inputcell.
cell.There
There isis no
no row
row
input cell,
input cell, so
soleave
leaveititblank
blank (see
(seethe
the bottom
bottom screenshot
screenshot to to the
the right).
right).

ItItisis important
importantto to understand
understand exactly
exactly what
whathappens
happens whenwhen youyou do
do this,
this, so
so read
readthis
this
paragraphseveral
paragraph several times
times until
until itit sinks
sinks in.
in. Excel
Excel takes
takes each
eachinterest
interest rate
rateinincolumn
column
N, substitutes
N, substitutes ititinto
into the
the blue
blue column
column input
inputcell
cell you
you designated
designated (cell(cell L7),
L7),
recalculates the formula in the green output cell with
recalculates the formula in the green output cell with this new interest ratethis new interest rate (and
(and
hence the
hence the link
link in
in red
redcell),
cell), and
and records
records the
the answer
answer in in the
thedata
datatable.
table. YouYou use
use aa
column input
column input cell
cellbecause
because the the possible
possible values
values of
of the
the input
input (the
(the interest
interestrates)
rates) are
are
listedin
listed inaa column.
column.

Youcan
You can tell
tell that
that you
you have
have aadatadata table
table by
by looking
looking at at any
any of
of the
the "answer"
"answer"cells,
cells,
thosebelow
those below the thered
red cell.
cell. ItItcontains
contains aaformula
formula =TABLE(,L7),
=TABLE(,L7), surrounded
surroundedby by curly
curly
brackets. The
brackets. Thepart
part inside
insidethe
theparentheses
parentheses shows
shows the therow
row and
andcolumn
columninputinput cells,
cells,
the first of which is blank in this example. The curly brackets indicate that this isis
the first of which is blank in this example. The curly brackets indicate that this
an array
an array formula.
formula.Essentially,
Essentially, this
this means
means that
that itit isis entered
entered inin all
all of
of the
the answer
answer
cells of
cells of the
thedata
data table
tableat at once,
once, as as aagroup.
group. You
You never
never need need to
to enter
enter this
this formula;
formula;
you create
you createthethetable
table asas explained
explained above.
above. However,
However, the the formula
formuladocuments
documents what what
the answer range
the answer range contains. contains.

ItItisis also
also possible
possibletoto capture
capture multiple
multiple outputs
outputs inin aa one-way
one-way data datatable.
table. An
An
example appears
example appears toto the
the right,
right, where
where the
the single
single input
input isis still
still the
the interest
interest rate,
rate, but
but
there are two outputs: monthly payment and total interest
there are two outputs: monthly payment and total interest paid. This table is paid. This table is
formed exactly
formed exactly as
as before
beforeexcept
except that
that the
the table
table range
range isis now
now 3-column
3-columnboxed-in
boxed-in
range.
range.
Tryit!
Try it! Create
Createaa one-way
one-waydata
data table
tableto
to the
theright
right that
that shows
shows the the monthly
monthly payments
payments
andthe
and the total
total interest
interest paid
paidfor
for each
each term
termfrom
from1212 to
to 48
48 in
in increments
increments of
of12.
12. (Scroll
(Scroll
to the
to the right
right for
for the
theanswer.)
answer.)

Tryititagain!
Try again! Delete
Delete the
thedata
data table
table you
youjust
just created.
created.Next,
Next, change
change the
the calculation
calculation
setting from
setting from Automatic
Automatic to to Automatic
Automatic Except
Except for
for Data
DataTables,
Tables, as
as explained
explained onon the
the
previousworksheet.
previous worksheet.Create
Create the
the data
data table
table again.
again. You
Youshould
should see
seethe
the same
same value
value
through the
through the table,
table, which
which isis disconcerting.
disconcerting. But
But you
you can
can press
press the
the F9
F9 key
key to
to get
get the
the
right answers. Then go back and change the calculation setting to
right answers. Then go back and change the calculation setting to Automatic. Automatic.
Tryit!
Try it! Create
Createaa one-way
one-waydata
data table
tableto
to the
theright
right that
that shows
shows the
the monthly
monthly payments
payments
and the total interest paid for each term from 12 to 48 in increments
and the total interest paid for each term from 12 to 48 in increments of 12. of 12. (Scroll
(Scroll
to the
to the right
right for
for the
theanswer.)
answer.)

Tryititagain!
Try again! Delete
Delete the
thedata
data table
table you
youjust
just created.
created.Next,
Next, change
change the
the calculation
calculation
setting from Automatic to Automatic Except for Data Tables, as
setting from Automatic to Automatic Except for Data Tables, as explained on explained on the
the
previousworksheet.
previous worksheet.Create
Create the
the data
data table
table again.
again. You
Youshould
should see
seethe
the same
same value
value
through the
through the table,
table, which
which isis disconcerting.
disconcerting. But
But you
you can
can press
press the
the F9
F9 key
key to
to get
get the
the
right answers.
right answers.Then
Then gogo back
back andand change
change the
thecalculation
calculation setting
setting to
to Automatic.
Automatic.
Price of car $20,000 Data table
Down payment $5,000 Interest rate Monthly payment
Amount financed $15,000 $459.74
Annual interest rate 6.50% 6.00%
Term (# of payments) 36 6.25%
6.50%
Monthly payment $459.74 6.75%
Total interest paid $1,550.46 7.00%

Price of car $20,000 Data table


Down payment $5,000 Interest Monthly payment Total interest
Amount financed $15,000 $459.74 $1,550.46
Annual interest rate 6.50% 6.00%
Term (# of payments) 36 6.25%
6.50%
Monthly payment $459.74 6.75%
Total interest paid $1,550.46 7.00%
Price of car $20,000 Data table
Down payment $5,000 Term Monthly payment Total interest
Amount financed $15,000
Annual interest rate 6.50%
Term (# of payments) 36

Monthly payment $459.74


Total interest paid $1,550.46
Data table
Term Monthly payment Total interest
$459.74 $1,550.46
12
24
36
48
Creating aa Two-Way
Creating Two-Way Data
Data Table
Table

Two-way tables
Two-way tables allow
allow you
you to
to vary
vary two
two inputs,
inputs, oneone along
alongaa row
rowand
andone
one along
alongaa
column, and capture a single output in the body of the table.
column, and capture a single output in the body of the table. The example toThe example to the
the
right illustrates
right illustrates this,
this, where
wherethethe annual
annual interest
interest rate
rate and
and the
the amount
amount of
ofthe
thedown
down
payment both
payment bothvary,
vary, and
and the
thesingle
singleoutput
output isis the
themonthly
monthlypayment.
payment.

To create
To create this
this table
table (which
(which has
hasalready
already been
been done):
done):

1.Enter
1. Enter the
theformula
formula =L10
=L10 for
for the
the single
single output
outputin inthe
the upper
upper lef
lef corner,
corner, the
thered
red
cell, of
cell, ofthe
the data
data table.
table.
2.Enter
2. Enter any
anysequence
sequenceof of down
downpayments
payments in in the
the top
top orange
orangerange
range and
and any
any
sequence of
sequence of interest
interest rates
ratesininthe
the left
left orange
orangerange.
range.
3.From
3. From the
the Data
DataTools
Tools group
group on on the
the Data
Data ribbon,
ribbon, select
selectData
Data Table
Table from
fromthe
the
What-If Analysis
What-If Analysis dropdown.
dropdown.
4.Enter
4. Enter L5
L5as
as the
the row
row input
input cell,
cell, and
and enter
enter L7
L7 as
as the
thecolumn
columninput
input cell
cell (see
(seeto
to the
the
right).
right).
Aswith
As with one-way
one-way tables,
tables, you
you can
can tell
tell you
you have
haveaa data
datatable
table by
by looking
looking at
at any
any of of the
the
"answer" cells in the table. Each contains the formula =TABLE(L5,L7),
"answer" cells in the table. Each contains the formula =TABLE(L5,L7), surrounded surrounded
by curly
by curly brackets.
brackets.This
This formula
formula indicates
indicates that
that L5
L5 isis the
therow
row input
input cell
cell and
and L7L7 isis the
the
column input
column input cell.
cell. In
In words,
words, the
the values
values for
for down
downpayment
paymentgo go across
across the
the top
top rowrow
of the
of thetable,
table, and
and the
the values
values for
for interest
interestrate
rate go
go down
downthe the left
left column
column of of the
thetable.
table.

Remember that
Remember thataa two-way
two-way data
data table
table allows
allows only
only one
one output.
output.IfIf you
you want
want toto
analyze multiple
analyze multipleoutputs,
outputs, you
you have
have to
to create
createmultiple
multiple data
datatables,
tables, one
one for
for each
each
output.
output.
Try it!
Try it! Create
Create aatwo-way
two-way data
datatable
tabletoto the
the right
right that
that shows
shows the
the total
totalinterest
interest paid
paid
for each
for each term
term from
from 12 12to
to 60
60in
in increments
increments of of 12,
12, and
and each
each down
down payment
payment from
from
$4000to
$4000 to $6000
$6000 inin increments
increments ofof $1000.
$1000.PutPut down
downpayments
payments along
along the
the top,
top, terms
terms
along the side. (Scroll to the right for the answer.)
along the side. (Scroll to the right for the answer.)
Price of car $20,000 Data table of monthly payment
Down payment $5,000 $459.74 $4,000 $5,000 $6,000
Amount financed $15,000 6.00%
Annual interest rate 6.50% 6.25%
Term (# of payments) 36 6.50%
6.75%
Monthly payment $459.74 7.00%
Total interest paid $1,550.46

Price of car $20,000 Data table of total interest paid


Down payment $5,000
Amount financed $15,000
Annual interest rate 6.50%
Term (# of payments) 36

Monthly payment $459.74


Total interest paid $1,550.46
Data table of total interest paid
$1,550.46 $4,000 $5,000
12
24
36
48
60
$6,000
Some Background
Some Background on
onTables
Tables

ItItisisvery
very common
common to to work
workwith
with "data
"datasets"
sets" in
in Excel,
Excel, where
whereaa data
dataset
set isis typically
typically aa rectangular
rectangular range
range
with "observations" in the rows, "attributes" in the columns, and attribute names
with "observations" in the rows, "attributes" in the columns, and attribute names in the top row. in the top row.
(Attributes are
(Attributes arealso
also called
calledvariables
variables or
or fields.)
fields.) AA typical
typical data
data set
set appears
appearsto to the
theright.
right. Each
Each row
rowisis an
an
observation on
observation onaa person,
person, and
andeach
each column
column isis lists
lists an
anattribute
attribute about
about the
thepeople.
people.

Excel users
Excel users have
have worked
worked with
with data
datasets
sets for
for years,
years, and
and for
for aa long
long time,
time, they
they were
were known
known somewhat
somewhat
informally as
informally as lists.
lists.But
But in
in Excel
Excel 2007,
2007, they
theygained
gainedmuch
much more
moreprominence
prominence and andbecame
became known
knownasas
tables. This
tables. This was
was aawelcome
welcome change.
change. You
You can
can do
do many
many useful
usefultasks
tasks with
with the
thenew
new tables
tablesthat
thatyou
youeither
either
couldn't do
couldn't do before
before or or could
could do
do only
only with
withextra
extra work.
work. Now
Now these
these tasks
tasks are
are easy.
easy.

Designating aa Data
Designating Data Set
Set as
as aa Table
Table

ItItisisnot
not enough
enough to to have
have aa rectangular
rectangular range
range of
of data
data toto apply
apply the
the new
new tools.
tools. You
You must
must designate
designate thethe
range as
range asaa table.
table.There
There are
are three
three ways
ways toto do
dothis,
this, all
all easy.
easy. For
For each,
each, make
make sure
sure any
any cell
cell in
in the
the table
table isis
selected. Then:
selected. Then:

1.Click
1. Click the
the Table
Table button
button near
nearthe
the left
left of
of the
the Insert
Insertribbon,
ribbon, or
or
2.Click
2. Click the
the Format
Formatasas Table
Tabledropdown
dropdown on on the
the Home
Home ribbon
ribbon and
and select
select any
any color
color style,
style, or
or
3.Press
3. Press Ctrl+t.
Ctrl+t.

Excel guesses
Excel guesses that
that the
therange
range"surrounding"
"surrounding" the
thecursor
cursor position
positionisis the
thetable
tablerange,
range, but
but you
youcan
can
override this
override this guess
guess ifif necessary.
necessary.

Try it!
Try it! Designate
Designate the
thedata
dataset
set to
to the
the right
right as
as aa table.
table.You
Youwill
will see
see that
that the
the formatting
formatting changes,
changes, and
andyou
you
will see two other important changes. First, there is a dropdown arrow next to
will see two other important changes. First, there is a dropdown arrow next to each attribute name.each attribute name.
These are
These are used
used for
for sorting
sortingand
and filtering,
filtering, as
asdiscussed
discussedbelow.
below. Second,
Second, ififthe
the cursor
cursor isis inside
insidethe
the table,
table,
there isis aanew
there new Table
Table Tools
Tools Design
Design tab tab and
and corresponding
corresponding ribbon.
ribbon.ItIt contains
contains the
thetools
tools for for manipulating
manipulating
thetable.
the table.

IfIf you
you no
no longer
longer want
want the
therange
rangeto
to be
bedesignated
designatedas as aatable,
table, you
youcan
can first
firstselect
selectaa table
table style
style that
that isis
"plain" (like
"plain" (like aaregular
regular worksheet).
worksheet). Then
Then click
clickConvert
Convert toto Range
Range ononthe
the Table
Table Tools
Tools Design
Design ribbon.
ribbon. The The
dropdown arrows
dropdown arrows will
will disappear.
disappear. Try
Trythis
this on
on the
the table
table you
you just
justcreated.
created.

Filtering in
Filtering in Tables
Tables

Oneof
One of the
the main
mainuses
uses of
of tables
tables isis filtering,
filtering, that
thatis,
is, hiding
hiding(but
(but not
notdeleting)
deleting) rows
rows that
that don't
don'tmatch
match
various conditions. Filtering is done through the dropdown arrows next to the
various conditions. Filtering is done through the dropdown arrows next to the column headings. This column headings. This
tutorialwon't
tutorial won't even
evenbegin
beginto to explain
explainall all of
of the
the options
options(because
(because there
there are
are so
so many),
many), but
butwith
with aa little
little bit
bit
of experimenting,
of experimenting, you
you should
shouldbe be able
ableto to master
master them
them in inno
no time.
time. Just
Just remember
remember that
that they
they build
build upon
upon
oneanother.
one another. For
For example,
example, ifif you
youfilter
filter on
on Gender
Gender so so that
thatonly
only males
malesare
are showing,
showing, and
and you
you then
then filter
filter
on Children so that only people with at least 2 children are showing, you will see
on Children so that only people with at least 2 children are showing, you will see only males with at only males with at
least 22children.
least children.

Try it!
Try it! Designate
Designate the
thedata
dataset
set to
to the
the right
right as
as aa table
table(if
(if you
youhaven't
haven'talready
already done
doneso),
so), and
and then
then
experiment with the filters. Note that there are number filters, text filters, and
experiment with the filters. Note that there are number filters, text filters, and date filters.date filters.
Oneof
One of the
the main
mainuses
uses ofof tables
tables isis filtering,
filtering, that
thatis,is, hiding
hiding(but
(but not
notdeleting)
deleting) rows
rows that
that don't
don'tmatch
match
various conditions.
various conditions. Filtering
Filteringisisdone
done through
through thethe dropdown
dropdown arrows
arrows next
next to
to the
the column
column headings.
headings. This
This
tutorial won't even begin to explain all of the options (because there are so many),
tutorial won't even begin to explain all of the options (because there are so many), but with a little bit but with a little bit
of experimenting,
of experimenting, you
you should
shouldbebe ableableto to master
master themthem in inno
no time.
time. Just
Just remember
remember thatthat they
they build
build upon
upon
oneanother.
one another. For
For example,
example, ifif you
youfilter
filter on
on Gender
Gender so so that
thatonly
only males
malesare
are showing,
showing, andand you
you then
then filter
filter
onChildren
on Children so
sothat
thatonly
only people
peoplewithwith at at least
least 22 children
children are are showing,
showing, youyou will
will see
seeonly
onlymales
maleswith
with atat
least 2 children.
least 2 children.
Try it!
Try it! Designate
Designate the
thedata
dataset
set to
to the
the right
right as
as aa table
table(if
(if you
youhaven't
haven'talready
already done
doneso),
so), and
and then
then
experiment with
experiment with the
the filters.
filters.Note
Notethatthatthere
there are
are number
number filters,
filters, text
textfilters,
filters, and
and date
date filters.
filters.
Experimentwith
Experiment with all
all of
of them.
them.

To clear
To clear aa filter,
filter, click
clickthe
the column's
column's dropdown
dropdown arrow
arrow and
and select
select the
the Clear
Clear Filter
Filter item.
item. To
To clear
clear all
all filters,
filters,
click the
click theClear
Clear button
button inin the
theSort
Sort && Filter
Filter group
group on
on the
the Home
Home ribbon.
ribbon.(It
(It isis also
also onon the
the Data
Dataribbon.)
ribbon.)
Try itit now
Try now byby clearing
clearing all
all your
your filters.
filters.

Sorting in
Sorting in Tables
Tables

You probably
You probablynoticed
noticedthat
thatwhen
when you you clicked
clicked aa column
columndropdown
dropdown arrow,
arrow, there
there are
are also
also sorting
sorting options.
options.
Sorting was
Sorting was already
already discussed
discussed in in aaprevious
previous worksheet,
worksheet, and
andthe
the options
options here
here are
are about
about the
the same.
same.ItIt isis
notclear
not clear that
that sorting
sorting in
in tables
tables provides
provides any
anyadvantages
advantages over
over sorting
sorting in
in regular
regular (non-table)
(non-table) data
datasets.
sets.

Summarizing with
Summarizing with the
the Total
Total Row
Row

Oneimportant
One important advantage
advantageof of aatable
table isis that
that you
you can
can summarize
summarize filtered
filtered data
data easily.
easily. To
To do
do so,
so, check
check the
the
Total Row
Total Row boxbox on
on the
the Table
Table Tools
Tools Design
Designribbon.
ribbon. This
Thisgenerates
generates aa "total"
"total" rowrow below
below the
the table.
table.By
By
default, itit shows
default, showsthethe sum
sumof of the
the values
values in in the
therightmost
rightmost column.
column. But But itit gives
gives you
you many
many more
more options.
options.
IfIf you
you select
select any
any cell
cell in
in the
the total
total row,
row, you
you will
will see
see aadropdown
dropdown list
list of
of ways
ways you you can
can summarize
summarizethe the
column (count, sum, average, and others). And importantly, if you then filter
column (count, sum, average, and others). And importantly, if you then filter the data, the summary the data, the summary
measureswill
measures will be
be only
only for
for the
thefiltered
filtereddata.
data.(This
(This couldn't
couldn't be
be done,
done, at at least
least not
not easily,
easily, before
before Excel
Excel
2007.)
2007.)
Try it!
Try it! Create
Create aatotal
total row
row for
for the
thetable
tableto
to the
the above
aboveright,
right, and
andshow
show summary
summary measures
measuresthat
thatseem
seem
appropriate. Then
appropriate. Then filter
filter in
insome
some way
wayand
andseesee whether
whether the
thesummary
summary measures
measureschange.
change.

Expanding Tables
Expanding Tables

AA feature
feature of
of tables
tables that
that business
business people
people will
willlove
love isis that
thatthey
they expand
expand automatically
automatically as as new
new data
data isis
added.For
added. For example,
example, suppose
suppose you
you designate
designate the
the data
data setsettoto the
the right
right as
as aa table.
table. Later
Later you
you add
add new
new
products to
products to the
the right
rightand/or
and/or new
newmonthly
monthlysales
sales at
at the
thebottom.
bottom.TheseThese will
will automatically
automaticallybe be part
partof
of the
the
table. Better yet, if you build a chart from the table, the chart will update automatically
table. Better yet, if you build a chart from the table, the chart will update automatically to include to include
new data.
new data.(The
(The same
same isis true
trueof
of pivot
pivottables,
tables, the
the topic
topic of of the
thenext
next worksheet,
worksheet, ifif they
they are
are built
builtfrom
from
tables.)
tables.)
Try it!
Try it! Designate
Designate the
thedata
dataset
set to
to the
the right
right as
as aa table.
table.Next,
Next, select
select the
the entire
entire table
table and
and insert
insertaa line
line
chart. By
chart. By default,
default, you
you should
should see
see aaline
linefor
for each
each product,
product, with
with time
time on
on the
the horizontal
horizontal axis.
axis.Now
Now add addaa
couple more
couple moremonths
months of of data
data at
at the
the bottom
bottom of of the
the table
table and
and add
add aa new
new product
product with
with some
some reasonable
reasonable
dataat
data atthe
the right
rightof
of the
thetable.
table. The
The chart
chart should
shouldupdate
updateautomatically!
automatically!
Try it! Designate the data set to the right as a table. Next, select the entire table and insert a line
chart. By
chart. By default,
default, you
you should
should see
see aaline
linefor
for each
each product,
product, with
with time
time on
on the
the horizontal
horizontal axis.
axis.Now
Now add
addaa
couple more
couple moremonths
months ofof data
data at
at the
the bottom
bottom ofof the
the table
table and
and add
add aa new
new product
product with
with some
some reasonable
reasonable
dataat
data atthe
the right
rightof
of the
thetable.
table. The
The chart
chart should
shouldupdate
updateautomatically!
automatically!
Person Birthdate Gender State Children Salary
1 8/5/1959 Male Illinois 1 $65,400
y aa rectangular
rectangular range
range
es in the top row. 2 10/15/1977 Female Wisconsin 2 $62,000
es in the top row.
right. Each row
ight. Each rowisis an
an 3 1/3/1981 Male Ohio 0 $63,200
e.. 4 5/5/1949 Male Indiana 2 $52,000
e known
known somewhat
somewhat 5 4/4/1987 Female Michigan 3 $81,400
became knownas
ecame known as 6 6/30/1949 Female Indiana 3 $46,300
tablesthat
tables thatyou
youeither
either
7 5/22/1949 Female Illinois 2 $49,600
8 10/30/1952 Male Michigan 1 $45,900
9 1/17/1957 Male Michigan 3 $47,700
10 9/18/1985 Female Indiana 1 $59,900
11 7/19/1953 Male Ohio 1 $48,100
12 12/10/1946 Female Wisconsin 0 $58,100
13 3/29/1986 Female Michigan 2 $56,000
14 12/12/1952 Female Indiana 2 $53,400
must designate
must designate thethe
any cell in
in the
the table
table isis 15 6/12/1977 Female Indiana 2 $39,000
ny cell
16 11/19/1989 Male Wisconsin 1 $61,500
17 9/6/1957 Male Ohio 0 $37,700
r style,
style, or
or 18 9/30/1970 Female Michigan 2 $36,700
19 10/24/1973 Male Wisconsin 2 $45,200
20 6/8/1978 Male Illinois 0 $59,000
e, but
e, but you
youcan
can
21 8/27/1990 Female Ohio 2 $54,300
22 2/9/1947 Male Indiana 1 $62,100
tting changes,
tting changes, and
andyou
you
each attribute name. 23 4/1/1989 Male Michigan 0 $78,000
each attribute name.
orr isis inside
insidethe
the table,
table, 24 3/12/1970 Male Wisconsin 0 $43,200
tools for
tools for manipulating
manipulating 25 3/28/1970 Male Ohio 1 $44,500
26 5/6/1963 Male Michigan 1 $43,300
aa table
table style
style that
that isis 27 5/7/1959 Male Indiana 3 $45,400
ols Design ribbon.
ls Design ribbon. The The 28 3/6/1987 Male Michigan 2 $53,900
29 2/9/1958 Male Illinois 1 $44,100
30 8/4/1955 Female Ohio 2 $31,000
31 11/9/1984 Male Indiana 2 $67,400
32 2/10/1961 Female Ohio 1 $59,300
33 4/1/1961 Female Ohio 1 $48,600
34 10/20/1961 Male Illinois 0 $58,400
35 4/25/1970 Male Michigan 2 $65,500
36 2/17/1977 Male Michigan 0 $46,900
37 4/13/1985 Male Michigan 2 $41,000
s that
that don't
don'tmatch
match
column headings. This 38 5/16/1966 Male Ohio 0 $89,300
olumn headings. This
ny), but
ny), butwith
with aa little
little bit
bit 39 10/28/1969 Female Indiana 3 $71,800
er that they
r that they build
build upon
upon 40 11/30/1958 Male Illinois 1 $95,000
ng, and you
g, and you then
then filter
filter
e only males with
e only males with at at

so), and
so), and then
then
date filters.
date filters.
s that
that don't
don'tmatch
match
column headings. This
olumn headings. This
ny), but with a little
ny), but with a little bit bit
er that they
r that they build
build upon
upon
ng, and you
g, and you then
then filter
filter
eeonly
onlymales
maleswith
with atat 41 9/27/1962 Male Illinois 1 $49,700
42 1/25/1968 Male Ohio 2 $71,700
43 10/15/1988 Female Wisconsin 0 $52,900
so), and
so), and then
then
date filters.
date filters. 44 2/11/1978 Female Michigan 0 $58,300
45 6/19/1974 Male Indiana 2 $82,000
em. To
To clear
clear all
all filters,
filters, 46 9/22/1989 Male Wisconsin 0 $41,300
em.
on the Data
n the Dataribbon.)
ribbon.) 47 7/25/1983 Female Wisconsin 1 $72,000
48 4/9/1956 Female Indiana 2 $73,500
49 2/9/1989 Male Ohio 2 $55,200
50 12/10/1960 Female Michigan 1 $57,000
51 8/6/1956 Male Michigan 2 $84,300
52 9/20/1981 Male Indiana 2 $68,900
53 1/31/1963 Male Wisconsin 2 $59,000
54 12/7/1973 Female Ohio 0 $83,200
55 12/3/1988 Male Wisconsin 0 $52,400
re also
re also sorting
sorting options.
options.
ee about
about the
the same.
same.ItIt isis
(non-table) datasets.
non-table) data sets.

ily.
ly. ToTo do
do so,
so, check
check the
the
low
ow the the table.
table.By
By
u many
many more
more options.
options.
an summarize
an summarizethe the
e data, the summary
e data, the summary
easily, before Excel
asily, before Excel

easuresthat
easures thatseem
seem
change.
hange.

Month Product1 Product2


Jan-08 $3,304 $3,411
ally as
ally as new
new data
data isis
Later you
you add
add new
new Feb-08 $4,663 $2,309
Later
maticallybe
matically be part
partof
of the
the Mar-08 $2,366 $3,165
matically to include
matically to include Apr-08 $2,662 $2,365
hey are
hey are built
builtfrom
from
May-08 $4,110 $4,149
Jun-08 $2,698 $1,319
e and
and insert
insertaa line
line Jul-08 $3,041 $4,087
ontal axis.
ontal axis.Now
Now addaddaa
with some
with some reasonable
reasonable Aug-08 $3,344 $2,752
Sep-08 $1,645 $4,189
Oct-08 $3,224 $2,656
and insert a line
ontal axis.
ontal axis.Now
Now add
addaa
with some
with some reasonable
reasonable

Nov-08 $1,391 $3,664


Dec-08 $3,284 $3,791
Jan-09 $4,279 $1,224
Feb-09 $3,259 $4,847
Mar-09 $3,395 $2,729
Apr-09 $3,980 $4,435
May-09 $1,149 $3,970
Jun-09 $4,321 $2,826
Jul-09 $4,547 $3,707
Aug-09 $1,698 $4,721
Sep-09 $1,100 $2,432
Oct-09 $1,485 $2,431
Background on
Background on Pivot
Pivot Tables
Tables

Pivottables
Pivot tables are
areaa manager's
manager's dream.
dream.They
Theyallow
allow you
you"slice
"slice and
anddice"
dice" data
data in
in aa
typical data set in all sorts of ways. Essentially, you use pivot tables to
typical data set in all sorts of ways. Essentially, you use pivot tables to breakbreak
down variables
down variables like
like revenue
revenue or
or items
items sold
sold by
by categories,
categories, such
such as
as by
by region,
region, by
by
month, by
month, bystore,
store, and
and soso on.
on.

Pivottables
Pivot tables have
have been
been in in Excel
Excel since
sincethe
the late
late 1990s,
1990s, and
and each
each new
new version
version hashas
changed them
changed themslightly.
slightly. Then
ThenExcel
Excel2007
2007 changed
changed themthem aa lot,
lot, or
or at
at least
least itit made
made
significantchanges
significant changesto to the
theuser
user interface
interface for
for pivot
pivot tables.
tables. This
Thiswas
wasevidently
evidentlyin in
response to
response tousers
userswhowho complained
complainedthat thatthe
the old
oldinterface
interface was
was not
not very
very user
user
friendly. With
friendly. With this
this new
new interface
interface (or
(or even
eventhethe older
older one),
one), an
anargument
argumentcan can bebe
madethat
made that no
no tool
tool in
in any
any software
software package
package enables
enables you
you to
toget
get asas much
much
informationas
information as quickly
quicklyand andeasily
easily as
asExcel's
Excel's pivot
pivot tables.
tables.
Probably the
Probably the only
onlything
thing that
that makes
makespivot
pivot tables
tablesdifficult
difficult for
for some
someusers
users isis that
that
there are
there areso
so many
many options.
options. Whole
Wholebooks
books have
have been
been written
written about
about pivot
pivot tables.
tables.
However, rather
However, rather than
thanread
readsuch
suchbooks,
books, you
youcan
canlearn
learnthe
theessentials
essentials asas explained
explained
below and
below and then
thenexperiment.
experiment. Pivot
Pivottables
tables are
are very
very forgiving,
forgiving, soso don't
don't worry
worry about
about
messing up.
messing up.

Creating aa Simple
Creating Simple Pivot
Pivot Table
Table

Thedata
The dataset
setto
to the
the right
right isis typical.
typical. Each
Each row
row isis aasale
sale to
to some
some customer.
customer.The
The last
last
two variables, Items Ordered and Total Cost, are numeric, so they
two variables, Items Ordered and Total Cost, are numeric, so they are candidates are candidates
for breaking
for breakingdown
down by by the
the categorical
categorical variables
variables to totheir
their left.
left.

To create
To create aapivot
pivottable,
table, place
placethe
the cursor
cursor anywhere
anywhere in
in the
the data
dataset
set and
andclick
click the
the
Pivot Table button on the Insert ribbon. Excel guesses the data range, which
Pivot Table button on the Insert ribbon. Excel guesses the data range, which you you
can override
can overrideifif necessary,
necessary, and
anditit asks
asks where
whereyou
youwant
want the
thepivot
pivot table
tableto
to be
be
placed.
placed.
Tryit!
Try it! Create
Createaa pivot
pivot table
table from
fromthis
this data
dataset,
set, and
and place
place itit on
on aa new
new worksheet.
worksheet.
Thenew
The new worksheet's
worksheet's name name will
will be
be something
something generic
generic like
like Sheet9,
Sheet9, and
and itit will
will be
be
located just
located just to
to the
the left
left of
of this
this worksheet.
worksheet. Rename
Renamethe thenew
new worksheet
worksheet Practice
Practice
PivotTable.
Pivot Table. (To
(Tokeep
keep from
from having
having toto go
go back
back and
and forth
forthbetween
between worksheets,
worksheets, you you
might want to copy this text box and the ones below to the
might want to copy this text box and the ones below to the new worksheet.) new worksheet.)

Youwill
You will see
see aablank
blank pivot
pivot table
table to
tothe
the left,
left, and
and ifif the
the cursor
cursor isis inside
insideit,
it, you
you will
will
see aaPivot
see PivotTable
TableField
Field List
List window
window on onthetheright
right and
andtwotwo PivotTable
PivotTableTools
Tools tabs
tabs
(Options and
(Options and Design)
Design) atatthe
the top.
top. (Remember
(Remember this:this: the
thefield
field list
list window
window and and thethe
pivot table
pivot table tabs
tabsare
are visible
visible only
only when
when thethe cursor
cursor isis inside
inside aapivot
pivot table.
table. SoSoifif they
they
disappear, you
disappear, you now
now know
know why.)
why.)

Thekey
The keyisis the
thefield
field list
liston
on the
theright.
right. The
The top
toppane
pane shows
shows all
all of
of the
the available
available fields
fields
(columns), and
(columns), and the
the bottom
bottom panepane shows
shows the
the four
four areas
areas you
you can
can drag
drag these
these to.
to.
Rather than
Rather than listen
listentoto aa long
long explanation,
explanation, try
try the
the following:
following:
DragGender
Drag Gender to tothe
the Row
Row Labels
Labels area,
area, Region
Region toto the
the Column
Column Labels
Labels area,
area, Paid
Paid With
With
to the
to the Report
ReportFilter
Filter area,
area, and
and Total
Total Cost
Cost to
to the
the Values
Values area.
area. You
You have
have just
just broken
broken
down Total
down Total Cost
Cost by
by Gender,
Gender, Region,
Region, and and Paid
Paid With.
With. Each
Each number
number inin the
the pivot
pivot
table isis the
table the sum
sumof of Total
Total Cost
Cost for
for its
its particular
particular category
category values.
values.
Thekey
The keyisis the
thefield
field list
liston
on the
theright.
right. The
The top
toppane
pane shows
shows all
all of
of the
the available
available fields
fields
(columns), and the bottom pane shows the four areas you
(columns), and the bottom pane shows the four areas you can drag these to.can drag these to.
Rather than
Rather than listen
listentoto aa long
long explanation,
explanation, try
try the
the following:
following:

DragGender
Drag Gender to tothe
the Row
Row Labels
Labels area,
area, Region
Region to
to the
the Column
Column Labels
Labels area,
area, Paid
Paid With
With
to the Report Filter area, and Total Cost to the Values area. You have
to the Report Filter area, and Total Cost to the Values area. You have just broken just broken
down Total
down Total Cost
Cost by
by Gender,
Gender, Region,
Region, and and Paid
Paid With.
With. Each
Each number
number in
in the
the pivot
pivot
table isis the
table the sum
sumof of Total
Total Cost
Cost for
for its
its particular
particular category
category values.
values.

Modifying aa Pivot
Modifying Pivot Table
Table

Here are
Here are some
someother
other things
things you
youcan
cando
do to
tothe
the pivot
pivot table
table you
you just
justbuilt:
built:

1.By
1. By default,
default, the
the sums
sums are
arefor
for all
all categories
categories of
of the
the Report
ReportFilter
Filter variable.
variable.To
To show
show
sums for
sums for VISA
VISA sales
sales only,
only, say,
say, click
click the
thedropdown
dropdownarrow
arrow next
nexttoto Paid
Paid With
Withand
and
select VISA.
select VISA.

2.You
2. Youcan
can hide
hide any
any row
row or
or column
column categories.
categories. For
For example,
example, click
click the
theColumn
Column
Labels dropdown
Labels dropdown list
listand
and select
select only
onlyMidwest
Midwest and
andWest.
West.

3.You
3. Youcancan change
change the
the way
wayTotal
Total Cost
Cost isis summarized
summarized and
and the
the way
way itsits values
values are
are
formatted. To
formatted. Todo
do so,
so, right-click
right-click any
any of
of the
the numbers
numbers inin the
the pivot
pivottable
table andandselect
select
Value Field
Value FieldSettings.
Settings.(You
(Youwill
will do
dothis
this often,
often, sosoremember
remember it.)it.) In
In the
the Summarize
Summarize byby
list, select Average. Then click the Number Format button and
list, select Average. Then click the Number Format button and select a number select a number
format in
format in the
the usual
usual way.
way.Now
Now youyou see
see the
the average
average of
of Total
Total Cost
Cost for for the
the various
various
categories.
categories.
4.In
4. In the
thebottom
bottompanepaneof of the
the field
field settings
settingswindow,
window, drag
drag Gender
Gender to
to the
the column
column
area and
area and Region
Regionto to the
therow
row area.
area. This
This isis called
called pivoting.
pivoting. (So
(Soguess
guesswhy
why they
they are
are
calledpivot
called pivot tables!)
tables!)

5.In
5. In the
thebottom
bottompanepaneof
of the
the field
field settings
settingswindow,
window, drag drag any
anyofof the
the fields
fields to
to aa
blank space
blank space on
on the
the worksheet
worksheet(or (or simply
simplyuncheck
uncheck its itsbox
box in
inthe
the top
toppane).
pane).This
This
removes the
removes thefield
fieldfrom
fromthe
thepivot
pivot table.
table.There
There isis no
norequirement
requirement that that each
each of
of the
the
four areas
four areas must
mustcontain
containaa field.
field.

6.You
6. Youcan
can have
havetwotwo(or(or even
evenmore)
more) fields
fields in
in aagiven
given area.
area. For
For example,
example, put
put both
both
Regionand
Region andTime
Time inin the
the row
row area.
area. ItItstarts
starts toto get
get"busy,"
"busy," but
butyou
you are
are certainly
certainly
allowed to
allowed to do
do it.
it.

7.You
7. Youcancan sort
sortthe
the values
values in in the
therow
row oror column
column area
area through
through the
thedropdown
dropdown
arrows, but
arrows, butthe
the sort
sort order
order might
might notnot be
bethe
thenatural
natural order.
order. For
For example,
example, drag
drag Time
Time
to the
to the row
row area
area(and
(and drag
drag any
any other
other variable
variable off).
off). The
The natural
natural order
order isis Morning,
Morning,
Afternoon, Evening,
Afternoon, Evening, but
but this
this isn't
isn't what
what you
you get
getwith
with aa sort.
sort. To
To sort
sort appropriately,
appropriately,
select the
select theMorning
Morningcell,
cell, and
and place
place your
your cursor
cursor at
at the
thebottom
bottomof of the
the cell
cell so
so that
thatitit
becomes aafour-way
becomes four-way arrow,
arrow, andand drag
dragititup
up above
above Afternoon.
Afternoon.

8.With
8. With the thecursor
cursor in in the
thepivot
pivot table,
table, click
click the
the PivotChart
PivotChart button
buttonon on the
the PivotTable
PivotTable
Tools Options
Tools Options ribbon,
ribbon, and and select
select aachart
chart type.
type. You
You not
notonly
only get
get aavery
very nice-looking
nice-looking
Excel chart,
Excel chart, but
but itit updates
updates automatically
automatically as as you
you make
make changes
changes inin the
the pivot
pivottable.
table.
That is,
That is, the
thepivot
pivot table
table and
and the
the corresponding
corresponding pivot
pivot chart
chart are
are perfectly
perfectly
synchronized. Make
synchronized. Makesome some changes
changes toto the
the pivot
pivottable
table to
to see
see what
what happens
happensto to the
the
chart. This
chart. Thisisisalmost
almost too too good
good totobe
be true!
true!
chart. This is almost too good to be true!

Summarizing and
Summarizing and Displaying
Displaying in
in Different
Different Ways
Ways

IfIf the
the field
fieldin
inthe
the Values
Values area
area isis numeric,
numeric, as
as itit usually
usuallyis,
is, you
you probably
probably want
want to
to
summarize ititby
summarize by sums
sums oror averages.
averages. But But you
youcan
can also
also summarize
summarize byby counts.
counts. Then
Then itit
doesn't matter
doesn't matterwhich
which field
fieldisis in
in the
the Values
Values area.
area.

Tryit!
Try it! Start
Start over
over by
bydragging
draggingeverthing
everthingoff
off the
the pivot
pivot table.
table. Now
Now drag
drag Region
Region to
to
therow
the row area,
area, Gender
Gender to
tothe
the column
column area,
area, and
and any
any variable
variable to
to the
the Values
Values area.
area.

IfIf you
youdrag
dragaa text
text variable
variable totothe
the Values
Values area,
area, you
you get
get counts
counts byby default.
default. But
But ifif you
you
dragaa numeric
drag numeric variable
variableto to the
theValues
Values area,
area, you
youwill
will have
have to
to right-click
right-clickany
any
number in
number inthe
thepivot
pivot table,
table, select
select Value
Value Field
Field Settings,
Settings, and
and select
select Count
Count to
to
summarize by.
summarize by. (If
(If you
youdo do the
the latter,
latter, it's
it'saa good
good idea
idea to
tochange
change the
the Custom
Custom Name
Name
in the Value Field Settings dialog box to Count, rather than Count
in the Value Field Settings dialog box to Count, rather than Count of Total Cost. of Total Cost.
Thereason
The reason isis that
that Total
Total Cost
Cost has
hasnothing
nothingto to do
do with
with the
the counts,
counts, sosothe
the default
default
label isis misleading.)
label misleading.) You You can
can also
also reformat
reformat the thenumbers
numbers ifif necessary.
necessary.

Each count
Each count shows
shows the
the number
number of
of customers
customers inin the
thecategory.
category. For
For example,
example, you
you
should see
should see that
that there
there are
are 43
43females
females from
from the
theMidwest.
Midwest.

Sometimesitit isismore
Sometimes moreinformative
informativetoto display
displaythethe counts
counts asas percentages.
percentages.To To do
do this,
this,
open the Value Field Settings dialog box, click the "Show values
open the Value Field Settings dialog box, click the "Show values as" tab, and as" tab, and
select "%
select "% of
of row"
row" from
from the
the dropdown
dropdown list.
list.You
You should
should see,
see, for
for example,
example, that
that
26.5% of
26.5% of all
all female
female customers
customers areare from
fromthethe NorthEast.
NorthEast. DoDo itit again,
again, but
butthis
this time
time
select "%
select "% of
of column".
column". NowNowyou
you should
should see,
see, for
for example,
example, that
that 32.26%
32.26%of of all
all South
South
customers are
customers are male.
male. You
You can
can experiment
experiment with with these
theseandandother
other "Show
"Show values
values as"
as"
options. ItItall
options. all depends
depends onon how
how you
you want
wantto to "tell
"tell the
the story."
story."

Grouping
Grouping
Another useful
Another useful feature
feature isis grouping.
grouping. When
When you
you drag
drag aa field
field to,
to, say,
say, the
therow
row area,
area,
you get
you get aarow
row for
for each
each distinct
distinct value
value of
of the
the field.
field. IfIf there
there many
manydistinct
distinctvalues,
values, the the
pivot table
pivot table becomes
becomes unwieldy
unwieldy and and probably
probably not notvery
very useful.
useful. InIn this
this case,
case, itit isis aa
good idea
good ideatoto group
grouponon the
thefield.
field.

Tryit!
Try it! Start
Start over
over by
bydragging
draggingallall of
of the
the fields
fields off
off the
thepivot
pivottable.
table. Then
Then drag
drag Date
Dateto
to
therow
the row area
area and
and Total
Total Cost
Cost to
tothe
the Values
Values area.
area.

Notethat
Note that there
there isis some
some summarizing
summarizing happening
happening here here because
because multiple
multiple sales sales
were made
were made on onsome
some of ofthe
the dates,
dates, but
but there
there are
are soso many
many dates
dates that
that itit isis difficult
difficult
to see
to see any
any interesting
interestingtrends
trends through
through time.
time.So
Soitit isisuseful
useful to
to group
group on
on dates.
dates.

Tryit!
Try it! Right-click
Right-click any
any date,
date, select
select Group,
Group, and
and then
then select
select Month.
Month. Now
Now you
you see
see
total sales
total sales in
in each
each of
of the
the four
four months.
months.

IfIf this
this data
dataset
set were
were over
over aamulti-year
multi-year period
period and
and you
yougrouped
groupedas as above,
above, you
you
would see all of the Januaries lumped together, and similarly
would see all of the Januaries lumped together, and similarly for the other for the other
months. To
months. Tosee
see them
them broken
broken down
down byby year,
year, the
the trick
trickisisto
to select
select Month
Month and
and Year
Year
in the
in theGroup
Group dialog
dialogbox.
box.
were made
were made ononsome
some ofofthe
the dates,
dates, but
but there
there are
are soso many
many dates
dates that
that itit isis difficult
difficult
to see
to see any
any interesting
interestingtrends
trends through
through time.
time.So
Soitit isisuseful
useful to
to group
group on
on dates.
dates.

Tryit!
Try it! Right-click
Right-click any
any date,
date, select
select Group,
Group, and
and then
then select
select Month.
Month. Now
Now you
you see
see
total sales in each of the four months.
total sales in each of the four months.

IfIf this
this data
dataset
set were
were over
over aamulti-year
multi-year period
period and
and you
yougrouped
groupedas as above,
above, you
you
wouldsee
would see all
all of
of the
theJanuaries
Januaries lumped
lumped together,
together, andand similarly
similarly for
for the
the other
other
months. To
months. Tosee
see them
them broken
broken down
down byby year,
year, the
the trick
trickisisto
to select
select Month
Month and and Year
Year
in the
in theGroup
Group dialog
dialogbox.
box.

Basing aa Pivot
Basing Pivot Table
Table on
on aa Table
Table

There isis aadistinct


There distinctadvantage
advantage totobuilding
building aa pivot
pivot table
table from
fromaa table
table as
as opposed
opposedto to
aa fixed
fixed range.
range. The
The advantage
advantage isis that
that ifif you
you decide
decide toto add
addrows
rows and/or
and/or columns
columns to
to
thetable,
the table, the
the table
tableexpands
expandsautomatically,
automatically, as as explained
explainedin inthe
the previous
previous
worksheet, and
worksheet, and the
the pivot
pivot table
table can
canthen
then be be refreshed
refreshed with
withthe
the click
click of
ofaa button
button to
to
accommodatethe
accommodate the new
new data.
data. That
That is,
is,youyou do
do not
not need
need toto build
build aa new
new pivot
pivottable.
table.

Tryit!
Try it! Designate
Designatethe thedata
data to to the
the right
rightas
as aatable.
table. ItIt will
will get
get aadefault
default table
table name,
name,
such as Table2, which you can change if you like. Then build
such as Table2, which you can change if you like. Then build a pivot table from a pivot table from
thetable.
the table. You
You will
will notice
noticethat
that the
the data
data source
source boxbox (labeled
(labeled Table/Range)
Table/Range) contains
contains
thename
the nameof of the
the table,
table, not
not aarange
rangeaddress.
address. This
This isis what
what you
you want.
want.Now
Now gogo back
back
andadd
and add aa new
new column
column to to the
the right
rightofof the
the table
table (possibly
(possibly with
withaa formula)
formula) and/or
and/or
addsome
add some extra
extradata
datatoto the
thebottom
bottomof of the
the table.
table.GoGo back
back to
to the
thepivot
pivot table
tableand
and
clickthe
click the Refresh
Refresh button
button on on the
the PivotTable
PivotTable Tools
ToolsOptions
Options ribbon.
ribbon.The Thepivot
pivot table
tableisis
automaticallypopulated
automatically populated with with the
thenew
new data,
data, aafeature
featurebusiness
business managers
managers will
will
love!
love!

Slicers (in
Slicers (in Excel
Excel 2010
2010 and
and more
more recent
recent versions
versionsonly)
only)

Excel 2010
Excel 2010introduced
introduced aa newnew feature
featurefor
for pivot
pivottables
tables called
called aa slicer.
slicer. See
Seethe
the Slicer
Slicer
worksheetin
worksheet in this
this tutorial
tutorial for
for more
moreinformation
information about
about this
thisfeature.
feature.
Date Day Time Region Paid With Gender Items Ordered Total Cost
10-Mar Mon Morning West VISA Female 4 $136.97
10-Mar Mon Morning West Mastercard Female 1 $25.55
10-Mar Mon Afternoon West VISA Female 5 $113.95
10-Mar Mon Afternoon NorthEast VISA Female 1 $6.82
10-Mar Mon Afternoon West Mastercard Male 4 $147.32
10-Mar Mon Afternoon NorthEast VISA Female 5 $142.15
11-Mar Tues Evening West Mastercard Male 1 $18.65
11-Mar Tues Evening South VISA Male 4 $178.34
11-Mar Tues Evening West Cash Male 2 $25.83
12-Mar Wed Morning MidWest Mastercard Female 1 $18.13
12-Mar Wed Morning NorthEast Mastercard Female 2 $54.52
12-Mar Wed Afternoon South VISA Male 2 $61.93
13-Mar Thurs Morning NorthEast VISA Male 3 $147.68
13-Mar Thurs Afternoon NorthEast Mastercard Male 1 $27.24
14-Mar Fri Morning West Mastercard Female 3 $46.18
14-Mar Fri Afternoon West VISA Male 5 $107.44
14-Mar Fri Afternoon South Cash Female 6 $96.53
14-Mar Fri Afternoon West VISA Female 4 $77.44
15-Mar Sat Morning South Mastercard Male 1 $15.19
15-Mar Sat Afternoon South Cash Male 1 $45.52
16-Mar Sun Morning West VISA Male 4 $157.05
16-Mar Sun Afternoon West VISA Male 2 $51.95
16-Mar Sun Evening West Mastercard Female 9 $429.98
17-Mar Mon Afternoon South VISA Female 1 $33.37
17-Mar Mon Evening West VISA Male 3 $71.84
18-Mar Tues Morning NorthEast Mastercard Female 5 $139.51
18-Mar Tues Afternoon South Mastercard Male 3 $78.46
18-Mar Tues Evening MidWest Mastercard Male 3 $125.13
19-Mar Wed Afternoon MidWest VISA Male 1 $14.76
19-Mar Wed Afternoon South Cash Female 2 $83.38
20-Mar Thurs Morning West Mastercard Female 3 $104.91
20-Mar Thurs Afternoon NorthEast VISA Male 4 $101.37
20-Mar Thurs Afternoon NorthEast VISA Female 2 $53.16
20-Mar Thurs Evening West VISA Female 2 $40.63
21-Mar Fri Morning West VISA Female 7 $286.41
21-Mar Fri Afternoon South Mastercard Female 2 $59.39
21-Mar Fri Evening NorthEast VISA Male 4 $185.45
22-Mar Sat Morning NorthEast Mastercard Female 2 $35.08
22-Mar Sat Morning MidWest Mastercard Male 2 $91.62
22-Mar Sat Morning NorthEast Cash Female 8 $155.50
22-Mar Sat Evening West VISA Male 4 $20.89
22-Mar Sat Evening West Mastercard Male 6 $186.29
22-Mar Sat Evening West Cash Female 1 $42.22
22-Mar Sat Evening West VISA Male 2 $42.19
23-Mar Sun Afternoon MidWest VISA Female 1 $47.86
24-Mar Mon Morning South Mastercard Female 3 $139.76
24-Mar Mon Morning NorthEast Mastercard Female 6 $186.42
24-Mar Mon Afternoon South Mastercard Female 1 $54.08
24-Mar Mon Afternoon West Mastercard Female 3 $84.98
24-Mar Mon Afternoon South Cash Female 2 $27.13
25-Mar Tues Morning West Mastercard Female 2 $54.70
25-Mar Tues Afternoon South Mastercard Female 5 $229.54
25-Mar Tues Evening West Cash Male 4 $124.21
26-Mar Wed Morning West VISA Female 2 $26.39
27-Mar Thurs Morning West Mastercard Female 4 $106.97
27-Mar Thurs Afternoon West Cash Female 8 $377.18
28-Mar Fri Morning NorthEast Mastercard Female 1 $24.31
28-Mar Fri Afternoon South Mastercard Female 1 $34.47
28-Mar Fri Afternoon West Mastercard Male 3 $106.19
28-Mar Fri Evening NorthEast VISA Male 2 $55.30
29-Mar Sat Morning NorthEast VISA Female 2 $82.98
29-Mar Sat Morning NorthEast Cash Male 4 $101.79
29-Mar Sat Morning MidWest Mastercard Male 3 $99.28
29-Mar Sat Morning NorthEast Mastercard Female 3 $100.09
29-Mar Sat Afternoon NorthEast Cash Female 3 $88.91
29-Mar Sat Afternoon MidWest Cash Male 2 $62.58
29-Mar Sat Afternoon South VISA Female 1 $28.87
29-Mar Sat Afternoon MidWest VISA Male 4 $141.29
29-Mar Sat Evening NorthEast Cash Male 4 $66.54
29-Mar Sat Evening South VISA Female 2 $69.03
30-Mar Mon Afternoon South Mastercard Female 2 $65.51
30-Mar Mon Evening West VISA Female 2 $35.59
31-Mar Wed Afternoon South VISA Female 7 $320.18
31-Mar Wed Afternoon MidWest Mastercard Male 5 $128.57
31-Mar Wed Evening West Mastercard Male 6 $248.42
31-Mar Wed Evening NorthEast Cash Male 2 $50.04
1-Apr Thurs Morning NorthEast Cash Male 4 $145.48
1-Apr Thurs Afternoon West Mastercard Female 9 $403.60
1-Apr Thurs Afternoon NorthEast Cash Female 6 $284.14
1-Apr Thurs Afternoon West Mastercard Female 1 $81.14
2-Apr Fri Morning MidWest Mastercard Female 3 $82.36
2-Apr Fri Afternoon MidWest Mastercard Female 2 $32.65
2-Apr Fri Afternoon NorthEast VISA Female 6 $200.70
2-Apr Fri Afternoon NorthEast Mastercard Female 3 $99.13
3-Apr Sat Morning South VISA Female 4 $85.88
3-Apr Sat Afternoon South Mastercard Male 3 $183.52
3-Apr Sat Afternoon West VISA Female 2 $53.87
3-Apr Sat Evening NorthEast Mastercard Male 3 $44.08
4-Apr Sun Morning MidWest VISA Female 1 $82.34
4-Apr Sun Afternoon South Cash Male 3 $151.29
5-Apr Mon Morning NorthEast VISA Male 5 $87.02
5-Apr Mon Afternoon MidWest VISA Male 2 $54.96
5-Apr Mon Afternoon MidWest Mastercard Female 1 $65.11
5-Apr Mon Afternoon NorthEast Mastercard Female 3 $76.69
5-Apr Mon Evening NorthEast VISA Female 2 $48.38
6-Apr Tues Morning NorthEast Cash Female 5 $76.64
6-Apr Tues Afternoon NorthEast VISA Female 2 $54.08
6-Apr Tues Afternoon South Mastercard Female 3 $130.00
6-Apr Tues Evening MidWest Mastercard Female 4 $218.29
7-Apr Wed Evening West VISA Male 1 $38.10
8-Apr Thurs Morning NorthEast VISA Male 4 $100.02
8-Apr Thurs Morning West Cash Female 4 $248.73
8-Apr Thurs Morning West Mastercard Female 2 $25.80
8-Apr Thurs Evening MidWest Cash Male 1 $52.83
9-Apr Fri Morning West VISA Male 3 $131.89
9-Apr Fri Morning NorthEast Mastercard Male 3 $82.69
9-Apr Fri Morning West Mastercard Male 1 $70.03
9-Apr Fri Morning NorthEast Mastercard Female 1 $102.86
9-Apr Fri Morning West Cash Male 4 $174.13
10-Apr Sat Morning South Mastercard Female 2 $49.80
10-Apr Sat Morning MidWest Cash Female 2 $29.97
10-Apr Sat Afternoon MidWest Mastercard Male 2 $82.53
10-Apr Sat Afternoon South Mastercard Female 4 $142.76
10-Apr Sat Evening NorthEast Cash Male 2 $72.58
10-Apr Sat Evening MidWest VISA Male 2 $55.39
11-Apr Sun Afternoon West VISA Female 4 $206.39
12-Apr Tues Morning MidWest Mastercard Female 4 $245.67
12-Apr Tues Morning NorthEast Mastercard Female 5 $265.69
12-Apr Tues Afternoon South Mastercard Female 3 $124.46
12-Apr Tues Afternoon NorthEast Mastercard Female 6 $206.26
13-Apr Wed Afternoon South Mastercard Female 7 $306.23
14-Apr Fri Morning South Cash Female 1 $48.12
14-Apr Fri Afternoon MidWest Mastercard Male 4 $113.95
14-Apr Fri Afternoon West VISA Female 6 $261.44
15-Apr Sat Morning South Cash Male 2 $59.90
15-Apr Sat Morning MidWest VISA Female 2 $49.73
15-Apr Sat Morning MidWest VISA Female 3 $65.06
15-Apr Sat Afternoon West VISA Male 4 $97.71
15-Apr Sat Afternoon NorthEast Cash Female 1 $49.84
15-Apr Sat Evening MidWest Cash Female 6 $233.94
15-Apr Sat Evening West Mastercard Female 9 $370.26
16-Apr Sun Afternoon West Cash Male 6 $313.11
16-Apr Sun Afternoon NorthEast Cash Female 6 $141.77
16-Apr Sun Evening South Mastercard Female 1 $27.99
17-Apr Mon Morning MidWest VISA Female 3 $81.34
17-Apr Mon Afternoon West VISA Female 2 $97.15
17-Apr Mon Evening West Cash Male 7 $352.49
18-Apr Tues Morning South VISA Female 3 $88.75
18-Apr Tues Afternoon NorthEast VISA Female 4 $107.95
18-Apr Tues Evening NorthEast Mastercard Male 5 $186.22
19-Apr Wed Morning MidWest Mastercard Female 4 $159.23
19-Apr Wed Afternoon MidWest Mastercard Female 2 $82.43
19-Apr Wed Evening NorthEast Mastercard Male 4 $99.42
20-Apr Thurs Afternoon NorthEast Cash Male 3 $79.32
20-Apr Thurs Evening South VISA Male 3 $160.01
20-Apr Thurs Evening West VISA Male 2 $51.99
21-Apr Fri Morning West VISA Female 8 $267.67
21-Apr Fri Afternoon NorthEast Mastercard Female 9 $429.22
21-Apr Fri Afternoon NorthEast Cash Female 1 $46.20
21-Apr Fri Afternoon NorthEast VISA Female 5 $240.02
22-Apr Sat Morning South Cash Male 4 $157.14
22-Apr Sat Afternoon MidWest Mastercard Female 5 $140.40
22-Apr Sat Evening NorthEast Mastercard Male 5 $204.93
23-Apr Sun Morning South VISA Female 2 $88.18
23-Apr Sun Afternoon South Cash Female 3 $95.47
24-Apr Mon Morning South Mastercard Female 5 $224.73
24-Apr Mon Morning West Mastercard Female 8 $344.73
24-Apr Mon Afternoon NorthEast VISA Female 4 $185.32
24-Apr Mon Afternoon South VISA Female 6 $297.31
24-Apr Mon Evening South Cash Male 4 $223.32
24-Apr Mon Evening South VISA Female 3 $164.40
25-Apr Tues Morning West Mastercard Female 2 $123.57
25-Apr Tues Evening NorthEast Mastercard Male 5 $236.97
26-Apr Wed Morning West VISA Female 2 $82.75
26-Apr Wed Morning South Cash Male 6 $307.75
26-Apr Wed Afternoon MidWest Cash Female 4 $200.73
27-Apr Thurs Morning MidWest VISA Female 4 $242.06
27-Apr Thurs Evening South VISA Male 4 $215.09
27-Apr Thurs Evening NorthEast Mastercard Male 3 $162.90
28-Apr Fri Afternoon West Mastercard Female 5 $214.31
28-Apr Fri Afternoon South Mastercard Female 1 $42.07
28-Apr Fri Evening NorthEast VISA Male 2 $69.05
28-Apr Fri Evening NorthEast VISA Female 4 $148.90
29-Apr Sat Morning NorthEast VISA Male 4 $105.74
29-Apr Sat Morning MidWest Mastercard Male 3 $138.32
29-Apr Sat Afternoon West Mastercard Male 2 $61.71
29-Apr Sat Evening South VISA Male 3 $120.11
29-Apr Sat Evening MidWest Mastercard Male 1 $72.80
29-Apr Sat Evening MidWest Mastercard Female 2 $134.86
29-Apr Sat Evening West VISA Male 4 $89.75
30-Apr Sun Morning West Mastercard Female 4 $220.04
30-Apr Sun Afternoon South Mastercard Female 3 $168.39
30-Apr Sun Evening NorthEast Mastercard Male 6 $277.80
1-May Mon Afternoon NorthEast VISA Female 3 $130.49
2-May Tues Evening NorthEast Cash Male 2 $94.39
3-May Wed Afternoon West Mastercard Female 4 $120.48
3-May Wed Afternoon South VISA Female 6 $304.95
4-May Thurs Evening West VISA Female 9 $389.79
5-May Fri Morning NorthEast VISA Female 4 $161.08
5-May Fri Afternoon NorthEast VISA Female 2 $69.61
6-May Sat Morning West VISA Female 3 $59.99
6-May Sat Morning MidWest Mastercard Male 2 $120.78
6-May Sat Morning West Cash Female 3 $82.30
6-May Sat Morning South VISA Female 2 $91.88
6-May Sat Morning West Mastercard Male 1 $87.10
6-May Sat Afternoon MidWest Mastercard Female 2 $70.10
6-May Sat Afternoon NorthEast Cash Female 2 $106.67
6-May Sat Evening NorthEast Mastercard Male 1 $34.31
6-May Sat Evening West VISA Male 3 $77.69
6-May Sat Evening West Mastercard Female 2 $85.31
7-May Sun Evening NorthEast Mastercard Female 1 $65.92
7-May Sun Evening MidWest Cash Female 1 $89.98
8-May Mon Morning West VISA Female 3 $102.07
8-May Mon Afternoon South VISA Female 4 $199.83
8-May Mon Evening South Cash Male 3 $134.21
8-May Mon Evening South Mastercard Male 4 $188.41
8-May Mon Evening West VISA Male 4 $102.72
8-May Mon Evening West Mastercard Male 2 $85.63
9-May Tues Morning West Cash Male 4 $206.87
9-May Tues Afternoon South Mastercard Female 2 $141.22
9-May Tues Evening West VISA Male 10 $463.40
9-May Tues Evening South Mastercard Female 5 $166.54
10-May Wed Morning MidWest Mastercard Female 6 $260.62
10-May Wed Afternoon MidWest VISA Female 1 $79.16
11-May Thurs Afternoon West Mastercard Female 6 $320.40
11-May Thurs Evening MidWest Cash Male 2 $79.01
12-May Fri Morning West Mastercard Female 2 $126.22
12-May Fri Evening NorthEast VISA Male 5 $263.45
13-May Sat Morning South Cash Male 3 $135.86
13-May Sat Afternoon West VISA Male 1 $98.74
13-May Sat Evening South Mastercard Female 1 $101.05
13-May Sat Evening NorthEast Cash Male 7 $361.60
14-May Sun Evening NorthEast VISA Female 3 $120.56
15-May Mon Morning West Mastercard Female 1 $52.68
15-May Mon Morning NorthEast VISA Female 3 $99.51
15-May Mon Afternoon South VISA Female 1 $85.29
15-May Mon Afternoon NorthEast Mastercard Female 3 $143.59
15-May Mon Afternoon South Mastercard Female 3 $197.13
15-May Mon Afternoon South VISA Female 3 $190.74
15-May Mon Evening West VISA Male 3 $111.44
16-May Tues Morning West VISA Male 3 $153.39
16-May Tues Afternoon MidWest Mastercard Female 2 $65.40
16-May Tues Evening NorthEast Mastercard Female 9 $448.20
16-May Tues Evening South Mastercard Male 2 $123.19
17-May Thurs Morning South Mastercard Female 5 $210.28
17-May Thurs Morning NorthEast Mastercard Female 7 $349.46
17-May Thurs Evening South VISA Male 4 $290.63
17-May Thurs Evening MidWest Mastercard Female 3 $103.03
18-May Fri Morning South Mastercard Male 2 $112.54
18-May Fri Afternoon MidWest VISA Male 8 $399.36
18-May Fri Evening South VISA Male 2 $68.18
19-May Sat Morning MidWest Mastercard Male 3 $146.58
19-May Sat Morning MidWest Cash Female 6 $309.50
19-May Sat Morning West Mastercard Male 5 $177.96
19-May Sat Morning South Mastercard Male 2 $119.46
19-May Sat Afternoon West Cash Female 3 $119.66
19-May Sat Afternoon MidWest Cash Female 4 $168.87
19-May Sat Afternoon South Cash Female 4 $192.39
19-May Sat Afternoon South VISA Female 2 $101.73
19-May Sat Afternoon NorthEast Mastercard Male 2 $74.94
19-May Sat Evening MidWest Cash Female 8 $291.30
20-May Sun Afternoon West Cash Female 3 $161.00
21-May Mon Afternoon West VISA Female 3 $116.01
21-May Mon Afternoon West VISA Male 2 $74.39
21-May Mon Evening NorthEast VISA Male 4 $226.25
21-May Mon Evening West Cash Male 3 $135.19
22-May Tues Morning West Mastercard Male 4 $126.16
22-May Tues Afternoon South Cash Female 4 $156.30
22-May Tues Afternoon South Mastercard Female 3 $73.42
22-May Tues Afternoon NorthEast VISA Female 7 $310.74
22-May Tues Afternoon NorthEast VISA Female 6 $296.26
22-May Tues Evening West Cash Male 2 $115.29
23-May Wed Evening West Mastercard Male 4 $212.94
24-May Thurs Morning South VISA Female 2 $85.93
24-May Thurs Afternoon West Mastercard Male 2 $80.02
24-May Thurs Afternoon NorthEast Cash Female 5 $286.17
25-May Fri Morning South VISA Female 4 $190.27
25-May Fri Afternoon NorthEast Mastercard Male 5 $265.24
25-May Fri Afternoon West VISA Female 7 $353.93
26-May Sat Morning NorthEast Mastercard Male 5 $314.77
26-May Sat Afternoon MidWest Mastercard Female 2 $169.23
26-May Sat Evening West VISA Female 3 $149.71
26-May Sat Evening MidWest VISA Male 2 $105.35
27-May Mon Afternoon South Mastercard Female 2 $111.47
27-May Mon Evening West VISA Male 9 $441.16
28-May Tues Morning MidWest VISA Female 5 $179.56
28-May Tues Evening South VISA Male 2 $83.15
29-May Wed Evening South Mastercard Male 4 $262.86
29-May Wed Evening MidWest Mastercard Male 2 $82.51
30-May Thurs Morning NorthEast VISA Female 5 $290.27
30-May Thurs Morning West Mastercard Female 5 $223.08
30-May Thurs Afternoon NorthEast VISA Female 3 $165.77
30-May Thurs Evening South Mastercard Female 2 $99.81
31-May Fri Morning NorthEast Mastercard Female 3 $158.95
31-May Fri Morning MidWest Mastercard Female 5 $280.99
31-May Fri Morning South Mastercard Female 4 $149.89
31-May Fri Afternoon South VISA Female 7 $363.52
31-May Fri Evening NorthEast VISA Male 2 $93.97
1-Jun Sat Afternoon NorthEast Mastercard Female 8 $391.97
1-Jun Sat Afternoon West VISA Female 5 $275.54
1-Jun Sat Afternoon NorthEast VISA Male 1 $115.55
1-Jun Sat Evening MidWest Mastercard Male 3 $125.00
1-Jun Sat Evening South Mastercard Female 1 $103.15
1-Jun Sat Evening NorthEast Mastercard Male 9 $256.70
1-Jun Sat Evening MidWest VISA Female 1 $117.99
1-Jun Sat Evening South VISA Female 2 $98.55
2-Jun Sun Morning MidWest Cash Female 2 $112.93
2-Jun Sun Evening South VISA Female 2 $76.30
3-Jun Mon Afternoon NorthEast Cash Female 2 $129.80
3-Jun Mon Evening South Mastercard Female 3 $140.25
4-Jun Tues Morning NorthEast Mastercard Male 3 $149.79
4-Jun Tues Morning NorthEast Mastercard Female 4 $172.20
4-Jun Tues Evening West VISA Female 3 $139.85
4-Jun Tues Evening West Cash Male 1 $96.46
4-Jun Tues Evening West VISA Female 3 $127.83
5-Jun Wed Evening NorthEast VISA Male 6 $215.88
6-Jun Thurs Morning NorthEast Mastercard Female 2 $133.49
6-Jun Thurs Evening West VISA Male 2 $117.33
7-Jun Fri Morning West VISA Female 2 $107.98
7-Jun Fri Afternoon MidWest VISA Female 6 $203.11
7-Jun Fri Afternoon West VISA Female 5 $193.33
7-Jun Fri Evening NorthEast Cash Male 7 $343.26
8-Jun Sat Morning NorthEast Mastercard Male 11 $485.01
8-Jun Sat Evening MidWest Mastercard Female 4 $221.93
8-Jun Sat Evening West Cash Male 2 $94.04
8-Jun Sat Evening NorthEast Mastercard Male 1 $113.37
9-Jun Sun Afternoon NorthEast Cash Male 5 $188.26
10-Jun Mon Afternoon West VISA Female 4 $170.19
10-Jun Mon Afternoon West Cash Female 4 $224.15
10-Jun Mon Afternoon NorthEast Cash Female 7 $352.32
10-Jun Mon Evening MidWest Cash Male 4 $257.18
10-Jun Mon Evening West VISA Male 2 $122.06
10-Jun Mon Evening NorthEast VISA Male 4 $239.95
11-Jun Tues Afternoon MidWest Mastercard Female 3 $124.44
11-Jun Tues Afternoon NorthEast VISA Male 4 $116.58
11-Jun Tues Afternoon MidWest Cash Female 2 $154.46
11-Jun Tues Evening MidWest Mastercard Male 1 $76.92
11-Jun Tues Evening South Mastercard Male 4 $194.85
12-Jun Wed Morning South Mastercard Female 6 $367.70
12-Jun Wed Evening NorthEast Cash Male 1 $119.50
12-Jun Wed Evening West Mastercard Male 7 $270.94
12-Jun Wed Evening West Cash Male 2 $94.71
13-Jun Thurs Morning South VISA Male 4 $154.01
13-Jun Thurs Morning MidWest VISA Female 5 $313.30
13-Jun Thurs Afternoon West VISA Male 7 $217.99
14-Jun Fri Afternoon NorthEast VISA Female 3 $127.22
14-Jun Fri Afternoon South Mastercard Male 1 $135.97
14-Jun Fri Afternoon West Mastercard Female 1 $87.14
14-Jun Fri Afternoon MidWest VISA Male 2 $96.77
14-Jun Fri Evening West Mastercard Female 1 $74.74
15-Jun Sat Morning South Cash Female 1 $117.48
15-Jun Sat Morning West VISA Male 2 $132.89
15-Jun Sat Morning NorthEast VISA Male 5 $230.26
15-Jun Sat Afternoon NorthEast VISA Male 10 $451.03
15-Jun Sat Afternoon MidWest Cash Female 3 $153.31
16-Jun Sun Morning MidWest Mastercard Male 3 $117.79
17-Jun Mon Morning West VISA Female 7 $357.32
17-Jun Mon Afternoon South VISA Female 7 $374.17
18-Jun Tues Afternoon NorthEast Mastercard Female 3 $122.28
18-Jun Tues Evening West Mastercard Male 2 $122.57
19-Jun Wed Evening South Cash Female 2 $134.59
19-Jun Wed Evening South VISA Male 1 $134.98
19-Jun Wed Evening MidWest Cash Male 1 $109.45
20-Jun Thurs Morning West VISA Female 3 $131.52
21-Jun Fri Morning MidWest VISA Female 1 $88.76
21-Jun Fri Morning South Mastercard Female 2 $174.28
21-Jun Fri Afternoon West Mastercard Male 1 $100.70
21-Jun Fri Afternoon NorthEast Mastercard Female 7 $387.43
21-Jun Fri Afternoon West Mastercard Female 3 $160.71
21-Jun Fri Evening South Mastercard Male 1 $105.91
21-Jun Fri Evening West Cash Male 1 $101.46
22-Jun Sat Morning West Mastercard Female 5 $271.67
22-Jun Sat Morning NorthEast Mastercard Male 1 $112.74
22-Jun Sat Afternoon NorthEast VISA Male 1 $96.42
22-Jun Sat Evening NorthEast VISA Female 6 $271.48
23-Jun Sun Morning NorthEast Mastercard Male 2 $156.79
23-Jun Sun Morning South Cash Female 5 $249.63
23-Jun Sun Afternoon West Mastercard Male 6 $278.62
23-Jun Sun Evening NorthEast VISA Male 2 $84.46
23-Jun Sun Evening NorthEast Mastercard Male 3 $221.17
23-Jun Sun Evening West Mastercard Male 4 $194.79
23-Jun Sun Evening South Mastercard Male 4 $199.22
24-Jun Mon Morning NorthEast VISA Female 2 $141.70
24-Jun Mon Afternoon MidWest VISA Female 4 $191.15
24-Jun Mon Afternoon NorthEast Mastercard Female 2 $142.41
25-Jun Tues Morning NorthEast Mastercard Female 3 $134.53
25-Jun Tues Afternoon West Cash Female 7 $374.37
25-Jun Tues Afternoon South VISA Female 3 $241.73
26-Jun Wed Morning MidWest Mastercard Female 4 $278.58
26-Jun Wed Morning South Mastercard Female 1 $106.25
26-Jun Wed Morning South Cash Female 3 $115.71
26-Jun Wed Afternoon NorthEast VISA Female 1 $78.34
26-Jun Wed Afternoon West Mastercard Female 4 $216.03
26-Jun Wed Afternoon West Mastercard Female 2 $140.01
26-Jun Wed Evening NorthEast Mastercard Male 8 $458.51
27-Jun Thurs Morning West VISA Female 4 $210.60
27-Jun Thurs Morning South Mastercard Female 4 $189.49
27-Jun Thurs Evening West Cash Male 7 $359.42
28-Jun Fri Morning West Cash Female 3 $132.06
28-Jun Fri Morning West VISA Female 5 $252.33
28-Jun Fri Morning MidWest Mastercard Male 2 $172.05
28-Jun Fri Afternoon West Mastercard Female 4 $206.19
28-Jun Fri Afternoon MidWest Mastercard Female 2 $143.98
28-Jun Fri Afternoon NorthEast VISA Female 4 $276.67
29-Jun Sat Morning MidWest VISA Male 1 $111.67
29-Jun Sat Afternoon NorthEast VISA Male 6 $268.39
29-Jun Sat Afternoon NorthEast Cash Female 3 $169.11
29-Jun Sat Afternoon West Mastercard Male 6 $242.46
29-Jun Sat Afternoon NorthEast VISA Male 4 $168.64
29-Jun Sat Afternoon NorthEast VISA Female 1 $107.59
GoalSeek:
Goal Seek: Solving
Solving One
One Equation
Equation in
in One
One Unknown
Unknown

Do you
Do you remember
remember your your high
highschool
school algebra
algebra class
class where
whereyou you had
had to
tosolve
solve aasingle
single
equation for a single unknown value? You can do this in Excel with
equation for a single unknown value? You can do this in Excel with the Goal Seek the Goal Seek
tool. The
tool. The unknown
unknown isis called
called aa changing
changing cell.
cell.Essentially,
Essentially, youyou want
wanttoto change
change the
the
valuein
value inthis
this cell
cell to
to force
forceaa formula
formula in
insome
some other
other cell
cell to
to be
be equal
equal to
to aa specified
specified
value.
value.

AA simple
simpleexample
exampleof of this
this appears
appearstoto the
theright.
right. Demand
Demand forfor aa company's
company's product
product isis
determined by
determined by aalinear
linear demand
demand curve:
curve: the
thehigher
higher the
the price,
price, the
thelower
lower the
the
demand.The
demand. Thecompany
company produces
produces exactly
exactlyenough
enoughto to meet
meet demand,
demand, withwiththe
the given
given
unit cost of production. The company wants to find the breakeven
unit cost of production. The company wants to find the breakeven price, that is,price, that is,
theprice
the price that
that makes
makes profit
profit equal
equal to
to 0.
0. This
This breakeven
breakeven price
pricecan
canbebe found
found with
with
Goal Seek.
Goal Seek. Here
Here are
are the
the steps.
steps.
1.Choose
1. Choose Goal Goal Seek
Seek from
fromthe
the What-If
What-If Analysis
Analysis dropdown
dropdown on on the
the Data
Dataribbon.
ribbon.
2.Fill
2. Fill in
in the
the resulting
resultingdialog
dialog box
box as
as shown
shown toto the
the right.
right.Specifically,
Specifically, the the price
pricein
in
theblue
the blue cellcell should
should be
bechanged
changedsosothat
thatthe
theprofit
profit in
in the
the red
red cell
cell isis 0.
0.

IfIf you
youtry
try this,
this, you
you will
will see seethat
that the
the result
result isn't
isn't very
very interesting.
interesting. ItIt turns
turns out
outthat
that
theprice
the price should
should bebe set
set to to 100,
100, at
at which
which point
pointthethe demand
demand isis 0,0, and
and this
this yields
yields no
no
sales and
sales and nono profit.
profit.ItIt isis probably
probably more
more interesting
interesting toto force
force the
the profit
profit toto some
some
positive value.
positive value.

Tryit!
Try it! See
See ifif you
you can
can change
change the
theprice
price so
so that
thatprofit
profit equals
equals $12,500.
$12,500.

Note: For
Note: For numerical
numerical reasons,
reasons, Goal
GoalSeek
Seekdoesn't
doesn't force
force profit
profitto
to exactly
exactly the
thevalue
value
you specify; it only gets close. For example, when you force profit
you specify; it only gets close. For example, when you force profit to 0, you might to 0, you might
get something
get something like
like the
the result
result in
in the
the middle
middle dialog
dialog box
box toto the
the right,
right, indicating
indicating that
that
profithas
profit has been
been forced
forced to
to the
the very
verysmall
small "current
"current value"
value" shown.
shown. IfIf this
thisisn't
isn'tclose
close
enough, you
enough, you can
canchange
change an an Excel
Excel setting
setting to
tomake
make itit closer.
closer.Open
Openthe the Excel
Excel
Options dialog box and select the Formulas group. (See to
Options dialog box and select the Formulas group. (See to the right.) Thenthe right.) Thenchange
change
the"Maximum
the "MaximumChange"
Change" to toaa smaller
smaller value
value(more
(more decimals).
decimals).
Unit cost 50
Unit price 60

Demand curve (linear)


Intercept 2000
Slope -20

Demand 800

Profit 8000
Optimizing with
Optimizing withSolver
Solver

Solver isisan
Solver an add-in
add-in that
thatships
ships with
with Excel
Excel but
but isis developed
developedby byFrontline
Frontline Systems,
Systems, not
not
Microsoft. It is used for constrained optimization models. There
Microsoft. It is used for constrained optimization models. There is much more about is much more about
Solver models
Solver models thanthan can
can possibly
possiblybe be covered
coveredhere,here, but
butbasically,
basically, you
you must
must first
first develop
develop
aaspreadsheet
spreadsheet modelmodel that
that starts
starts with
withnumerical
numerical inputs
inputs and
and values
valuesof of decision
decision variables
variables
(calledchanging
(called changing cells),
cells), and
andthenthen uses
uses formulas
formulas that
that capture
capturethe thebusiness
business logic
logic and
and
eventually lead to an objective, such as profit or total cost, that you
eventually lead to an objective, such as profit or total cost, that you want to maximize want to maximize
or minimize.
or minimize.ThenThenyou youfill
fill out
out aaSolver
Solver dialog
dialog box
box to
to indicate
indicate the
the objective,
objective, the
the
changingcells,
changing cells, constraints
constraintsthat thatmust
mustbebe satisfied,
satisfied, and
and some
someoptions.
options.When
Whenyou you click
click
theSolve
the Solve button,
button, thethe add-in
add-in usesuses powerful
powerful algorithms
algorithmsto to find
find the
the optimal
optimal solution.
solution.

AA simple
simpleoptimization
optimization model
model appears
appears to to the
theright.
right. TheThe objective
objective isis to
to find
find the
theminimal
minimal
cost way
cost wayto to send
sendunits
units of
of some
some product
product from
from manufacturing
manufacturing plants plants to to customer
customer
regions so
regions so that
that plant
plant capacities
capacities are
arenotnot exceeded
exceededand and regional
regional demands
demands are aremet.
met. The
The
blue cells contain given inputs (the unit cost of transportation from
blue cells contain given inputs (the unit cost of transportation from various plant sites various plant sites
tovarious
to various regions,
regions, the
thedemands
demands in in the
theregions
regions andand the the capacities
capacities ofofthe
the plants),
plants), the
the
red cells
red cells are
are the
the changing
changingcells,
cells, and
andthethe gray
gray cell
cell isis the
the objective
objectiveto to minimize.
minimize.You Youcancan
check the
check the formulas
formulasin inthe
the yellow
yellow andand gray
graycells
cells that
that capture
capture the
the business
business logic.
logic.(It
(Itisis
very simple
very simple forfor this
thismodel,
model, but
but the
the logic
logic can
can be
be much
much more more complex
complex in in other
other models.)
models.)

You then
You then invoke
invoke Solver
Solver from
from the
theData
Dataribbon
ribbonandandfill
fill out
outits
its main
main dialog
dialogbox
boxas as shown
shown
tothe
to the right.
right.Make
Make suresure to
to check
check the
theNon-Negative
Non-Negativeoption
option andand to
to choose
choosethethe Simplex
Simplex LP
LP
method. When you click the Solve button, the solution to the right
method. When you click the Solve button, the solution to the right will be found,will be found,
regardless of
regardless of the
the original
original values
valuesin
inthe
the red
red cells.
cells. This
This solution
solution minimizes
minimizes total
total cost,
cost,
whilesatisfying
while satisfying capacity
capacity and
and demand
demandconstraints.
constraints.

Note: IfIf Solver


Note: Solver isis not
noton onyour
your Data
Data ribbon,
ribbon, you
you need
need to to add
add itit in.
in. Open
Open the
the Excel
Excel
Options dialog
Options dialog box,box, then
thenAdd-ins,
Add-ins, andand then
then the
the Go
Gobutton.
button.Check
Check the the Solver
Solver item
item to
to
add itit in.
add in. IfIf Solver
Solver isn't
isn'tin
in the
thelist,
list, you
you will
will need
need toto run
runthe
theOffice
Officeinstaller
installer to
to install
install it.
it.
(See the
(See theAdd-ins
Add-ins Buttons
Buttons worksheet
worksheetin inthis
this tutorial
tutorial for
for aa quicker
quicker way way to
to get
getto to the
theadd-
add-
ins list
ins list that
that was was introduced
introduced in inExcel
Excel 2010,
2010, andand see
seethe
the New
New Solver
Solver worksheet
worksheet for for
changes to
changes to Solver
Solver in
in Excel
Excel 2010.)
2010.)
Unit shipping costs
To
Region 1 Region 2 Region 3 Region 4
From Plant 1 $131 $218 $266 $120
Plant 2 $250 $116 $263 $278
Plant 3 $178 $132 $122 $180

Shipping plan, and constraints on supply and demand


To
Region 1 Region 2 Region 3 Region 4 Total shipped Capacity
From Plant 1 150 0 0 300 450 <= 450
Plant 2 100 200 0 0 300 <= 600
Plant 3 200 0 300 0 500 <= 500
Total received 450 200 300 300
>= >= >= >=
Demand 450 200 300 300

Objective to minimize
Total cost $176,050
Introduction to
Introduction to Importing
Importing External
External Data
Data into
into Excel
Excel

Excel's strength
Excel's strengthlieslies in
in its
its ability
ability toto analyze
analyzedata.
data.However,
However, the the data
datayou
youwant
want toto
analyze will not always reside in an Excel worksheet. It might
analyze will not always reside in an Excel worksheet. It might be on a Web site, in be on a Web site, in
aa text
text file,
file, or
or in
inaa database.
database.The Thequestion,
question, then,
then, isis how
how you
youcancanimport
importthe thedata
data
you need
you need intointo Excel.
Excel. Fortunately,
Fortunately, Excel Excel has
has some
some veryvery powerful
powerful toolstools for
for
importing data,
importing data, and,
and, starting
startingwithwith Excel
Excel 2007,
2007, these
thesetools
tools are
are prominently
prominently
displayed on
displayed onthe
the left
left side
side of of the
the Data
Data ribbon,
ribbon, as
asshown
shown to to the
the right.
right. The
Thenextnext few
few
sheets explain
sheets explain howhow toto use
use these
these import
import options.
options.
Getting Data
Getting Data from
from aa Built-in
Built-inConnection
Connection

When you
When you import
import data
datafrom
from any
any external
external source,
source, Excel
Excelcreates
creates aa small
small text
text file
file that
that
stores information about the source. You can see a list of all known sources
stores information about the source. You can see a list of all known sources by clicking by clicking
theExisting
the ExistingConnections
Connections button
button totothe
the right.
right.In
In particular,
particular, Microsoft
Microsoft created
createdthe the three
three
connections listed
connections listedto
to the
the right
rightfor
for your
your convenience.
convenience. As As indicated,
indicated, they
they all
all refer
refer toto
MSN Web
MSN Web sites.
sites.

Try it!
Try it! Click
Click the
the Existing
Existing Connections
Connections button
button and andthen
thenthe
the Currency
Currency Rates
Rateslink.
link.You
Youwillwill
seethe
see theImport
Import Data
Data dialog
dialog box
box to
to the
the right,
right, where
where you
you can
canselect
selectthe
thelocation
location for
for the
the
imported data.
imported data.Note
Notethat
thatthe
the imported
imported data,
data, listed
listed below
below starting
starting in
incolumn
columnK, K, are
are
live. If you open this file tomorrow and click Refresh All from the Data ribbon,
live. If you open this file tomorrow and click Refresh All from the Data ribbon, you will you will
get the
get the latest
latest currency
currency rates.
rates.

Note: Unfortunately,
Note: Unfortunately, this
this doesn't
doesn't work
work in
in Excel
Excel 2013.
2013. For
For some
some reason,
reason, Microsoft
Microsoft
decided to remove these built-in connections.
decided to remove these built-in connections.
--> -->
Currency Rates Provided by MSN Money
Click here to visit MSN Money

Name In US$Per US$


Argentine Peso to US Dollar 0.25387 3.939
Australian Dollar to US Dollar 0.89174 1.121
Bahraini Dinar to US Dollar 2.6503 0.377
Bolivian Boliviano to US Dollar 0.14225 7.03
Brazilian Real to US Dollar 0.56529 1.769
British Pound to US Dollar 1.5598 0.641
Canadian Dollar to US Dollar 0.9608 1.041
Chile Peso to US Dollar 0.00198 505.2
Chinese Yuan to US Dollar 0.14715 6.796
Colombian Peso to US Dollar 0.00055 1828
Czech Koruna to US Dollar 0.05151 19.413
Danish Krone to US Dollar 0.17212 5.81
Euro to US Dollar 1.2822 0.78
Egyptian Pound* to US Dollar 0.17549 5.699
Hong Kong Dollar to US Dollar 0.12869 7.771
Hungarian Forint to US Dollar 0.0046 217.4
Indian Rupee to US Dollar 0.02156 46.38
Indonesia Rupiah to US Dollar 0.00011 8970
Japanese Yen to US Dollar 0.01171 85.38
Jordanian Dinar to US Dollar 1.4096 0.709
Kenyan Shilling to US Dollar 0.01234 81.05
South Korean Won to US Dollar 0.00085 1172
Kuwaiti Dinar to US Dollar 3.4708 0.288
Morocco Dirham to US Dollar 0.11569 8.644
Malaysian Ringgit to US Dollar 0.31949 3.13
Mexican Peso to US Dollar 0.07853 12.734
Norwegian Krone to US Dollar 0.16165 6.186
Omani Rial to US Dollar 2.5967 0.385
Peruvian New Sol to US Dollar 0.35613 2.808
Philippine Peso to US Dollar 0.02221 45.02
Pakistani Rupee to US Dollar 0.0116 86.21
Saudi Riyal to US Dollar 0.2666 3.751
Singapore Dollar to US Dollar 0.73779 1.355
South African Rand to US Dollar 0.13713 7.292
Swedish Krona to US Dollar 0.13536 7.388
Swiss Franc to US Dollar 0.96899 1.032
Taiwan Dollar to US Dollar 0.03132 31.926
Thai Baht to US Dollar 0.03167 31.58
Tunisian Dinar to US Dollar 0.67833 1.474
Emirati Dirham to US Dollar 0.27221 3.674

United States Dollar 1 1


Venezuelan Bolivar to US Dollar 0.23283 4.295

Data providers
Copyright 2010 Thomson Reuters. Click for Restrictions.
Quotes supplied by Interactive Data Real-Time Services.

MSN Money Microsoft Office Update


Discover Investor's tools, columns, Get the latest from Microsoft
and more! Office
MSN privacy
Legal
Advertise
RSS
Feedback
About our ads
Site map

2010 Microsoft
Web Queries
Web Queries

To say
To say the
the least,
least, there
there isis an
an abundance
abundance of of interesting
interesting data
data on
on the
the Web.
Web.Because
Because Web
Web authors
authors
can design
can design their
their sites
sites in
in aa variety
variety ofof ways,
ways, there
there isis no
noguarantee
guarantee that
that the
the Web
Webdata
data can
can be
be
imported easily into Excel, but it is worth trying with a Web query, a very simple
imported easily into Excel, but it is worth trying with a Web query, a very simple and powerful and powerful
tool.
tool.
To understand
To understandhow how Web Webqueries
queries work,
work, you
youneed
needto to understand
understand aa little
little about
about WebWeb pages.
pages.They
They
are all written in HTML, a markup language that has "tags" to identify different
are all written in HTML, a markup language that has "tags" to identify different parts of a page. parts of a page.
Onesuch
One such tag
tag isis the
the Table
Table tag.
tag. ItItoften
often indicates
indicatesaa rectangular
rectangular array
array of
of data
data ---- what
what you
you think
think of
of
asaa table
as table ---- but
but itit isis also
also used
used for for all
allsorts
sortsof
of things
things that
thataren't
aren'treally
reallytables.
tables. InInany
any case,
case, aaWeb
Web
query can
query can import
import anything
anything that thatisis surrounded
surrounded by by table
table tags.
tags.You
Youcan
can then
thendecide
decide which
which
"tables" are of interest
"tables" are of interest to you. to you.

Try it!
Try it! First
Firstopen
open your
your browser,
browser, locate
locate aaWeb
Web page
page that
thathas
has data
datayou
youwant
want to
to import,
import, and
and copy
copy
its URL.
its URL. ForFor this
this example,
example, use
usethe
the URL
URL

http://www.kelley.iu.edu/albrightbooks/scores.htm
http://www.kelley.iu.edu/albrightbooks/scores.htm
(This isis my
(This myown
own data
dataset
set for
for illustration.
illustration. Hopefully,
Hopefully, you
you can
can find
find more
more interesting
interestingWeb Webpages!)
pages!)
Then click the From Web button on the Data ribbon. This opens
Then click the From Web button on the Data ribbon. This opens the New Web Query dialogthe New Web Query dialog
boxto
box to the
the right.
right.Paste
Pasteyour
your URL
URL into
into the
the Address
Address boxboxand
and click
clickGo.Go. The
The Web
Web page
pagewill
will open,
open,
withyellow
with yellow arrows
arrowscorresponding
corresponding to to the
the table
table tags
tags on
on the
thepage.
page. Find
Findthe
theone(s)
one(s) youyouwant
wantand
and
click them,
click them, which
which changes
changes them
them to togreen
greencheck
check marks.
marks. Then
Then click
click Import.
Import.The
TheImport
Import Data
Data
dialog box
dialog box to
to the
the right
rightlets
lets you
youchoose
choose where
where toto start
startthe
theimport.
import.(The (The data
data for
for this
this example
example
appears below,
appears below, starting
starting inincolumn
columnB. B. Just
Justmake
make sure
sure there
there isis plenty
plenty ofof blank
blank space
spacebelow
below and
and
tothe
to the right
right of
of the
the selected
selectedcell.)
cell.)

Excel keeps
Excel keeps aa link
link to
tothe
the source
source of of this
thisdata.
data. To
To prove
prove this
this to
to yourself,
yourself, click
click the
the Connections
Connections
button on
button on the
the Data
Data ribbon
ribbon to tosee
see the
the Workbook
Workbook Connections
Connections dialog
dialogbox boxtoto the
theright.
right. Now
Now youyou
can do
can doseveral
several things.
things. First,
First, in
in case
casethethe Web
Web data
datachange
change through
through time,
time, you you can
canclick
click Refresh
Refresh to to
get the
get the newest
newestdata.data. Second,
Second, you youcan
canclick
click Properties,
Properties, then
thenthethe Definition
Definitiontab, tab, and
and then
then the
the
Edit Query
Edit Query button
button to to return
return to tothe
the New
New Web
WebQuery
Query dialog
dialog box.
box.You
You can can also
also rename
renamethe the
connection, as
connection, as was
was done
done here,
here, from
fromthethe Properties
Properties button.
button. Finally,
Finally, ifif you
youdon't
don't want
wantaa live
live link
link
tothe
to the Web
Web page,
page, youyou can
can click
click Remove.
Remove.

StudentID Total Points Course Grade


1 880 B+
2 935 A
3 830 B
4 890 B+
5 915 A-
6 840 B
7 785 C+
8 730 C
9 810 B-
10 905 A-
11 865 B
12 720 C-
13 895 B+
14 835 B
15 965 A
Importing Data
Importing Data from
from aa Text
TextFile
File

Datasets
Data sets are
are often
often stored
stored in
in "plain
"plain vanilla"
vanilla" text
textfiles,
files, usually
usuallywithwith aa.txt,
.txt, .dat,
.dat, or
or .prn
.prnextension,
extension, simply
simply
because everyone can view text files. All you need is a text editor, such as Notepad.
because everyone can view text files. All you need is a text editor, such as Notepad. Fortunately, ExcelFortunately, Excelhas
has
aawizard
wizard for
for importing
importingdata
data from
fromaa text
text file
fileinto
into Excel.
Excel. ItItisis easy
easyto
to use,
use, but
but you
youhave
have to
tobe
be careful
careful that
that
everything "lines
everything "lines up"
up" properly
properlyininthe
the import.
import.

Textfiles
Text filescome
comein in two
two varieties:
varieties: fixed
fixedwidth
width and
and delimited.
delimited. In In aa fixed
fixedwidth
widthdatadata set,
set, each
each variable
variablestarts
starts in
in
thesame
the samecolumn.
column. ForFor example,
example, First
FirstName
Namemight
might bebein in columns
columns 1-15,1-15, Last
Last Name
Name might
might bebeinincolumns
columns16- 16-
30, and
30, and soso on.
on.This
This isis aacarryover
carryover from
from the
the old
old days
days of of IBM
IBM punched
punched cards,
cards, but
butfixed
fixed width
width text
textfiles
files are
are
still fairly
still fairly common.
common.In In contrast,
contrast, in
inaa delimited
delimited text
text file,
file, pieces
pieces ofof data
data are
are separated
separatedby byaa delimiter
delimiter
character, the
character, the most
most common
common beingbeing aa space,
space, aa tab,
tab, aa common,
common, and and aa semicolon.
semicolon. You You can
can tell
tell that
thataa data
data set
set
isis delimited
delimited whenwhen youyouopen
openititin
in aa text
text editor
editor because
because the thecolumns
columnswon't won't line
line up;
up; they
they are
are "ragged."
"ragged."

Once you
Once you understand
understand this
this distinction,
distinction, importing
importingtext
textdata
data isis easy.
easy.To
To do
do so,
so, click
click the
theFrom
From Text
Text button
button on
on
the Data ribbon, and then browse to find your text file. This launches a three-step wizard,
the Data ribbon, and then browse to find your text file. This launches a three-step wizard, shown in the shown in the
three dialog
three dialogboxes
boxesto
to the
the right.
right.

1.In
1. In the
the first,
first, you
youcan
cansee
see from
fromthe
the data
datain
in the
thefirst
firstfew
few rows
rows that
that the
thedata
data are
are not
notfixed
fixed width,
width, so
so
Delimited is the correct choice. (You also have the option to start the import at a row
Delimited is the correct choice. (You also have the option to start the import at a row other than the other than thefirst
first
row. Text
row. Textfiles
files often
oftenhave
have"junk"
"junk" you
youdon't
don't want
want in inthe
the first
first few
few rows.)
rows.)

2.In
2. In the
the second
second dialog
dialogbox,
box, you
you can
can choose
choose the
thedelimiter,
delimiter, in
in this
this case,
case, aa comma.
comma.

3.In
3. In the
the third
third dialog
dialog box,
box, you
youcan
canfine-tune
fine-tune the the import,
import, but
but itit usually
usuallysuffices
suffices to
toclick
click the
the Finish
Finish button.
button.IfIf
any fine-tuning
any fine-tuningisis necessary,
necessary, you
youcan
can do
do itit in
in Excel.
Excel.

Thereisisaa final
There final dialog
dialogbox,
box, not
not shown
shown here,
here, where
whereyou
youcan
can select
select the
thelocation
location of
of the
the imported
imported data.
data. For
For
this example,
this example, thetheimported
imported data
data are
are listed
listedbelow.
below.

Always look
Always lookcarefully
carefully at
at the
theimported
imported data
data and
and make
make sure
sure everything
everything lines
lines up
up correctly.
correctly.IfIf ititdoesn't,
doesn't, you
you
either have to fix the imported data or fix something in the original text file. One "small"
either have to fix the imported data or fix something in the original text file. One "small" error canerror can
completely mess
completely mess up up the
the data
data to
to be
be analyzed.
analyzed.

Faculty Support Staff Supply Budget


Credit Hours Research Pubs
Business
150 70 5
15 225
Education
60 20 3
5.4 70
Arts & Sciences
800 140 20
56 1300
HPER
30 15 1
2.1 40
extension, simply
xtension, simply
ortunately, Excelhas
ortunately, Excel has
oobe
be careful
careful that
that

ach variable
ach variablestarts
starts in
in
ht be
ht beinincolumns
columns16- 16-
width textfiles
idth text files are
are
yaa delimiter
delimiter
an tell
an tell that
thataa data
data set
set
yy are
are "ragged."
"ragged."

rom Text button


om Text button on
on
zard, shown in
ard, shown in thethe

ed width,
ed width, so
so
other than thefirst
other than the first

the Finish button.


he Finish button.IfIf

mported data.
mported data. For
For

ly.
y. IfIf ititdoesn't,
doesn't, you
you
all" error
all" error can can
Importing Data
Importing Data from
from aa Database
Database

Theprevious
The previous two
two worksheets
worksheets explain
explainhow
how to to import
import data
datafrom
from the
the Web
Webor or from
fromaa
text file. Although these operations are common, they probably
text file. Although these operations are common, they probably aren't as aren't as
common as
common asthe
the importing
importing method
method described
described here:
here: importing
importingdata
data from
fromaa
database. This
database. This isis aa huge
huge topic,
topic, and
andthis
this tutorial
tutorial only
only scratches
scratches the
thesurface.
surface.IfIf you
you
areinterested
are interested in in more
more details,
details, an
anexcellent
excellent and
andeasy-to-read
easy-to-read source
source isis Tim
Tim
Zapawa's book
Zapawa's book Excel
Excel2007
2007 Advanced
Advanced Report
ReportDevelopment.
Development. (By (Bythe
the time
time you
you read
read
this, there
this, theremight
mightbe be aaversion
version for
for Excel
Excel 2010
2010or or even
even aamore
morerecent
recent version
versionof of
Excel.)
Excel.)
There are
There are many
many database
databasepackages
packagesavailable
available for
for storing
storing data,
data, including
including Microsoft
Microsoft
Access(part
Access (part of
of the
the Office
Office suite)
suite) and
andmany
manyserver-based
server-based systems
systems such
such asas
Microsoft's SQL
Microsoft's SQL Server,
Server, Oracle's
Oracle's RDBMS,
RDBMS, IBM's
IBM's DB2,
DB2, andand others.
others.Fortunately,
Fortunately, allall of
of
thesestore
these storedata
data ininessentially
essentially the
the same
same way:
way: as
as related
related tables,
tables, where
where each
each table
table
stores information
stores informationaboutaboutaa given
given entity
entity such
such as
as aaproduct,
product, aacustomer,
customer, or or aa
vendor. Also,
vendor. Also, they
theyall
all use
use essentially
essentiallythe
thesame
same query
querylanguage,
language, SQLSQL (Structured
(Structured
Query Language),
Query Language), to to retrieve
retrieve specific
specific subsets
subsets ofof the
the data.
data. Because
Becauseof of this
this
commonality across
commonality acrossdatabase
database packages,
packages, technologies
technologies have have been
been developed
developedover over
the past two decades that allow users (often programmers)
the past two decades that allow users (often programmers) to import databaseto import database
datainto
data into applications,
applications, including
including Excel.
Excel.

Thesimplest
The simplest wayway toto import
import database
databasedata datainto
into Excel,
Excel, andand the
theonly
only one
onedescribed
described
in detail here, is to use the From Access button to the
in detail here, is to use the From Access button to the right. After you then right. After you then
browsefor
browse for an
an Access
Access database
database file,file, you
youhave
havetwo
twooptions.
options.TheThefirst
first isis to
to import
import aa
single entire
single entire table.
table. Unfortunately,
Unfortunately, this this isis quite
quite limiting.
limiting. ForFor example,
example, ifif you you want
want
to know
to know about
about customers
customers and andorders
orders they
theyhave
haveplaced,
placed, youyou need
needdata
data from fromaa
Customers table
Customers table and
and ananOrders
Orders table;
table; aa single
singletable
table doesn't
doesn'tsuffice.
suffice. TheThe second
second
possibilityisis more
possibility more flexible.
flexible.You
You cancan import
import data
datafromfromaa named
named query
query in in an
an Access
Access
file. (The
file. (Thelist
listto
to the
the right
right includes
includes several
several named
named queries
queriesfrom
fromthethefamous
famous
Northwind database
Northwind databaseprovided
providedby by Microsoft.)
Microsoft.) ThisThis means
means that
thatyou
youshould
shouldfirst first
create queries of interest in Access, and save them, before
create queries of interest in Access, and save them, before importing the data importing the data
into Excel.
into Excel. OfOf course,
course, this
thisassumes
assumesthat thatyou youknow
know how how toto create
create queries
queries through
through
Access's user
Access's user interface.
interface. This
This isis not
not difficult,
difficult, but
but itit takes
takes some
some practice.
practice.

Other import
Other importoptions
options appear
appear under
under thetheFrom
From Other
Other Sources
Sources dropdown
dropdownlist, list,
shown to
shown tothe
the above
above right.
right.The
Themost
most common
common of of these
these isis From
From Microsoft
Microsoft Query.
Query.
Again, Zapawa's
Again, Zapawa's book bookdescribes
describes this thismethod
method in in great
greatdetail,
detail, so
so only
only the
the outline
outline of of
theprocedure
the procedure isis givengivenhere.
here. Basically,
Basically, ititisisaa three-step
three-stepprocess,
process, andandititisisquite
quite
easyonce
easy once you
youget
get usedused to
to it.
it.In
In the
the first
first step,
step, you
youidentify
identify the
the data
data source
source andand the
the
type of
type of database
database you you have
have(Access,
(Access, SQLSQL Server,
Server, Oracle,
Oracle, or or whatever).
whatever). In In case
case ofof aa
server-based system,
server-based system, you you must
mustidentify
identify thethe server
server andand probably
probablyprovide
providean an
accepted username
accepted username and and password.
password. In In the
thesecond
second step,step, you
youcreate
create aa query
query forfor the
the
data you want. You can do this through a user interface that
data you want. You can do this through a user interface that is very similar to the is very similar to the
onein
one inAccess,
Access, or
or you youcan
canenter
enter an an SQL
SQL statement
statement directly.
directly. Finally,
Finally, ininthe
the third
third
step, you
step, youtell
tell Microsoft
Microsoft QueryQuery to to return
returnthe thedata
data to toExcel,
Excel, inin aalocation
location of of your
your
choice.As
choice. As with
with WebWeb queries,
queries, thisthiscreates
creates aa link
link to
tothethe underlying
underlying database
database
source, so
source, so that
that ifif there
there are
arechanges
changes to tothe
the database,
database, you you can
can dodo aa refresh
refresh inin Excel
Excel
to get
to get the
the latest
latestdata.
data.

Admittedly, itit takes


Admittedly, takes some
some practice
practice to
to master
master the
thevarious
various options
options for
for importing
importing
database data into Excel, but this is a great skill to have. Companies
database data into Excel, but this is a great skill to have. Companies typically typically store
store
their data
their datainin databases
databases because
because this
this isis exactly
exactlywhat
whatdatabases
databases areare good
good at:
at: storing
storing
data.But
data. But databases
databases aren't
aren't good
good at
at data
dataanalysis,
analysis, which
which isis Excel's
Excel'sstrength.
strength. SoSo the
the
moreyou
more youknow
know about
aboutimporting
importing database
database data
datainto
into Excel,
Excel, the
the more
more valuable
valuable you
you
become.
become.
Admittedly, itit takes
Admittedly, takes some
some practice
practice to to master
master the
thevarious
various options
options for
for importing
importing
database data
database datainto into Excel,
Excel, but
but this
this isis aagreat
greatskill
skill to
to have.
have.Companies
Companies typically
typically store
store
their data in databases because this is exactly what databases are
their data in databases because this is exactly what databases are good at: storing good at: storing
data.But
data. But databases
databases aren'taren't good
good at
at data
dataanalysis,
analysis, which
which isis Excel's
Excel'sstrength.
strength. SoSo the
the
moreyou
more youknow
know aboutaboutimporting
importing database
database data datainto
into Excel,
Excel, the
the more
more valuable
valuable you
you
become.
become.
Tools for
Tools for Making
Making Your
Your Applications
Applications More
More Professional
Professional

As you
As you become
becomemore
moreandand more
more an anExcel
Excel power
power user,
user, you
you will
will probably
probably find
find that
that
you are creating Excel applications for your colleagues, not just for yourself.
you are creating Excel applications for your colleagues, not just for yourself. In In
this case,
this case, you
youwant
want toto make
make the
the applications
applications as
as professional
professional as as possible.
possible.This
This
often involves
often involves writing
writing macros
macros (with
(withthe
theExcel
Excel VBA
VBA programming
programming language)
language) to
to
automate certain
automate certain tasks.
tasks. This
This tutorial
tutorial doesn't
doesn't attempt
attemptto to teach
teachyou
youVBA,
VBA, but
butitit
does illustrate
does illustrate some
some tools
tools that
that require
require no
no programming
programming and and can
can really
really make
make aa
difference. You
difference. You might
might bebesurprised
surprisedhow
how easy
easy some
some ofof them
them are.
are.
General Documentation
General Documentation

There isis nothing


There nothing worse
worsethan
than getting
getting aa spreadsheet
spreadsheet from
from someone
someonewith
with no
no
documentation. All you see are a lot of meaningless numbers and possibly aafew
documentation. All you see are a lot of meaningless numbers and possibly few
not-well-thought-outlabels.
not-well-thought-out labels. This
This isis aa very
verybad
bad practice,
practice, and
andyou
you shouldn't
shouldn't be
be
guilty of
guilty of it.
it. There
Thereare
areaa number
number ofof things
things you
you can
can do
do to
to document
documentyour
your work.
work.OfOf
course, you
course, you should
should use
use descriptive
descriptivelabels
labels and
andaa clear,
clear, logical
logicalstructure,
structure, but
but you
you
can do
can do more
more thanthan this.
this.Specifically,
Specifically, youyou can
caninclude
includecell
cell comments
comments and
and text
text boxes,
boxes,
as explained
as explained below.
below.

Cell Comments
Cell Comments

AA cell
cell comment
comment isis useful
useful when
when you you want
wanttoto explain
explainsomething
something that
thatisisprobably
probably
not obvious
not obviousin inaa particular
particular cell.
cell. You
You will
will know
know aacell
cell contains
contains aa comment
commentwhenwhen
you see a little red mark in the upper right corner of the cell. You
you see a little red mark in the upper right corner of the cell. You can see the can see thecell
cell
comment by
comment byhovering
hovering the
thecursor
cursor over
over the
thecell.
cell. By
By default,
default, aa cell
cell comment
comment starts
starts
with the
with the owner's
owner's name,
name, but
but you
you can
can delete
delete this
thisname
name ifif you
you like.
like.

To insert
To insertaa cell
cell comment
comment in in aa cell,
cell, right-click
right-click the
thecell.
cell. IfIf there
there isis no
no existing
existing cell
cell
comment, you
comment, you will
will see
see an
an Insert
InsertComment
Comment item.
item. IfIf there
there isis an
anexisting
existing cell
cell
comment, you
comment, you will
will see
see Edit
EditComment
Comment and and Delete
Delete Comment
Comment items. items. (See
(See the
the
screenshots to
screenshots to the
theright.)
right.)

Tryit!
Try it! Add
Addthe
thefollowing
followingcell
cell comment
comment to
to the
the blue
blue cell
cell to
to the
the right:
right: Sales
Salesare
are in
in
$1000s. Then
$1000s. Then change
changethe
thecomment
comment to:
to: Monthly
Monthly sales
sales inin $1000s.
$1000s. Then
Thendelete
delete the
the
cell comment.
cell comment.

For more
For moreon oncell
cell comments,
comments, check
check out
out the
the Comments
Commentsgroup group on
on the
the Review
Review
ribbon. You
ribbon. You might
might not
not ever
ever use
use all
all these
these buttons,
buttons, but
butthey
they could
could be
behandy
handyifif
someonegives
someone gives you
youaa spreadsheet
spreadsheet with
with loads
loads of
of cell
cell comments,
comments, andand you
you want
want to
to
browse through them quickly.
browse through them quickly.

Text Boxes
Text Boxes

When you
When youadd addexplanations
explanations to to your
your worksheets,
worksheets, do doyou
you tend
tend to
to start
start typing
typing in
in aa
cell, and
cell, and when
whenititgetsgets long
longenough,
enough, you
you continue
continue typing
typing ononthe
thenext
next line,
line, etc.?
etc.? AA
lot of
lot of people
people do dothis.
this. ItItisisnot
not aa good
good habit,
habit, mostly
mostly because
because ofof the
the difficulty
difficulty of
of
editing.ItIt isis much
editing. much better
better to to use
use text
textboxes,
boxes, asas you
yousee
see throughout
throughout this
this tutorial.
tutorial.
Text boxes
Text boxesare are much
much better
better for for explanations
explanations than
than cells
cells because
because they
theyhave
have word
word
wrap. They
wrap. They areare essentially
essentiallymini-word
mini-word processors
processors that
that can
can be
be edited
edited (and
(and moved
moved
or resized)
or resized) easily.
easily. You
You should
shoulduse use them
them in
in virtually
virtually every
every spreadsheet
spreadsheet you you create!
create!

To insert
To insertaa text
textbox,
box, click
click the
theText
Text Box
Boxbutton
button onon the
the Insert
Insertribbon
ribbon (see
(see to
to the
the
right, which
right, whichisisfrom
from Excel
Excel 2010),
2010), and
and drag
dragaa text
text box
boxin in some
somearea
areaof
ofthe
the
worksheet.Then
worksheet. Then start
start typing.
typing.It's
It's as
as easy
easy as
as that.
that.

Youmight
You mightalso
also want
want to
to change
changethe
the appearance
appearanceof of the
the text
text box.
box. ToTodo
do so,
so, click
click itit
twice so
twice so that
that the
the border
border becomes
becomes aasolid
solid line
line(it's
(it's aa dotted
dotted line
line after
after the
the first
first
editing.ItIt isis much
editing. much better
better to
to use
use text
textboxes,
boxes, asas you
yousee
see throughout
throughout this
this tutorial.
tutorial.
Text boxes
Text boxesare are much
much better
better for
for explanations
explanations than
than cells
cells because
because they
theyhave
have word
word
wrap. They are essentially mini-word processors that can be edited
wrap. They are essentially mini-word processors that can be edited (and moved (and moved
or resized)
or resized) easily.
easily. You
You should
shoulduseuse them
them in
in virtually
virtually every
every spreadsheet
spreadsheet you
you create!
create!

To insert
To insertaa text
textbox,
box, click
click the
theText
Text Box
Boxbutton
button on
on the
the Insert
Insertribbon
ribbon (see
(see to
to the
the
right, which is from Excel 2010), and drag a text box in some
right, which is from Excel 2010), and drag a text box in some area of the area of the
worksheet.Then
worksheet. Then start
start typing.
typing.It's
It's as
as easy
easy as
as that.
that.

Youmight
You mightalso
also want
want to
to change
changethe the appearance
appearanceof of the
the text
text box.
box. ToTododo so,
so, click
click itit
twice so that the border becomes a solid line (it's a dotted line
twice so that the border becomes a solid line (it's a dotted line after the first after the first
click). Then
click). Then right-click
right-click and
and choose
choose the
theFormat
Format Shape
Shapeitem.
item. This
This brings
bringsupup aadialog
dialog
boxwhere
box where you
you can
can make
make all all sorts
sorts of
of changes.
changes. For
For example,
example, in inthis
this tutorial
tutorial all
all text
text
boxes have
boxes have aalight
light gray
grayfill
fill and
and aashadow.
shadow.IfIfyou
youlike
like the
theappearance,
appearance, you you can
can again
again
right-click and
right-click and choose
choose the
the Set
Setasas Default
Default Text
Text Box
Box item.
item. Then
Thenevery
everyother
other text
text box
box
you create
you createinin that
that workbook
workbook will will automatically
automatically have
have thethe same
sameappearance.
appearance.

Tryit!
Try it! Create
Createaa text
text box
box to
tothe
the right
right and
and enter
enter some
sometext.
text.You
Youwill
will see
see that
that itit
automatically has the same appearance as the rest of the text boxes
automatically has the same appearance as the rest of the text boxes in this in this
tutorial. Now
tutorial. Now change
change thetheappearance
appearance of of your
your new
new text
text box
box in
in some
some way.
way.
Sales
15.3
14.7
9.6
12.1
14.2
Background on
Background on Conditional
Conditional Formatting
Formatting

Of all
Of all the
the tools
toolsavailable
available inin Excel,
Excel, conditional
conditional formatting
formattingisisarguably
arguably the the coolest.
coolest.
As the name implies, conditional formatting allows you to
As the name implies, conditional formatting allows you to format cells dependingformat cells depending
on conditions
on conditions youyouspecify.
specify. The
The coolcool part
part isis that
that the
the formatting
formatting changes
changes
automaticallyifif the
automatically thecell
cell values
valueschange.
change.ForFor example,
example, suppose
suppose you you use
useconditional
conditional
formatting to
formatting to color
color aa cell
cell red
red ifif its
its value
value isis greater
greater than
than 100.
100. IfIf its
its current
current value
value isis
90, it won't be red, but if you change its value to 110,
90, it won't be red, but if you change its value to 110, it will turn red it will turn red
automatically.
automatically.
Conditional formatting
Conditional formattingwas was available
availablebefore
before Excel
Excel 2007,
2007, but butititwasn't
wasn'tvery
very
prominent, and most users didn't even know it was available.
prominent, and most users didn't even know it was available. Now it is very Now it is very
prominent, right
prominent, right in
in the
the middle
middle of
of the
the Home
Home ribbon.
ribbon. ItIt isis also
also much
much easier
easier to
to use.
use.
As illustrated
As illustratedbelow,
below, many
many uses
uses of
of conditional
conditional formatting
formatting are are really
reallyeasy,
easy, but
but aa
few are
few are tricky.
tricky.

Applying Some
Applying Some Simple
Simple Conditional
Conditional Formatting
Formatting

AA typical
typical use
useof of conditional
conditional formatting
formattingisis to to color
color all
all "high"
"high" values
values one
one color
color andand
all "low"
all "low" values
values another
another color.
color. In
In the
theexamexamscores
scores toto the
theright,
right, suppose
supposeyou you want
want
to color
to color all
all high
high scores
scores green
green and
and all all low
low scores
scores red,
red, where
where aahigh
high score
score isis greater
greater
thanthe
than thevalue
value inin cell
cell N19
N19 and
and aalowlow score
score isisless
less than
thanthethe value
value in
in cell
cellN20.
N20. To To do
do
so:
so:
1.Select
1. Select allall exam
exam scores
scores in
in column
column K.
K.
2.Click
2. Click the
theConditional
Conditional Formatting
Formatting dropdown,
dropdown, then thenHighlight
HighlightCell
Cell Rules,
Rules, and
and then
then
Greater Than.
Greater Than.
3.In
3. In the
theGreater
Greater Than
Than dialog
dialog box,
box, enter
enter aa cell
cell reference
reference to
to the
the top
top blue
blue cell
cell and
and
select a green format of your
select a green format of your choice. choice.
4.Repeat
4. Repeat steps
steps 22and
and 33in
inthe
theobvious
obvious way
way forfor the
thelow
low values.
values.
Tryit!
Try it! Perform
Perform the
theabove
abovesteps.
steps.Then
Then change
changethe
the values
values in
in the
theblue
blue cells
cells and
and
watch how the formatting changes automatically.
watch how the formatting changes automatically.
To delete
To delete the
the formatting,
formatting, click
click Conditional
Conditional Formatting
Formattingand
andthen
then Clear
Clear Rules.
Rules.

To change
To change the
the formatting
formatting rules,
rules, click
clickConditional
Conditional Formatting
Formattingand
and then
thenManage
Manage
Rules.
Rules.

Other Built-in
Other Built-in Conditional
Conditional Formatting
Formatting Possibilities
Possibilities

As you
As you can
can see
see when
when you
you click
click the
the Conditional
Conditional Formatting
Formattingdropdown,
dropdown, there
thereare
areaa
lot of
lot of built-in
built-in choices
choices that
thatare
arevery
very easy
easy to
to apply.
apply.Try
Try out
out some
someofof the
thefollowing:
following:

TheHighlight
The Highlight Cell
Cell rules
rules let
let you
you format
format numbers
numbers that
that satisfy
satisfyinequalities,
inequalities, as
as in
in the
the
example above,
example above, and
and they
they also
also let
let you
you format
format text
text or
or dates
dates that
thatsatisfy
satisfy natural
natural
conditions.
conditions.
Other Built-in
Other Built-in Conditional
Conditional Formatting
Formatting Possibilities
Possibilities

As you
As you can
can see
see when
when you
you click
click the
the Conditional
Conditional Formatting
Formattingdropdown,
dropdown, there
thereare
areaa
lot of
lot of built-in
built-in choices
choices that
thatare
arevery
very easy
easy to
to apply.
apply.Try
Try out
out some
someofof the
thefollowing:
following:

TheHighlight
The Highlight Cell
Cell rules
rules let
let you
you format
format numbers
numbers that
that satisfy
satisfyinequalities,
inequalities, as
as in
in the
the
example above, and they also let you format text or dates that satisfy
example above, and they also let you format text or dates that satisfy naturalnatural
conditions.
conditions.
TheTop/Bottom
The Top/Bottomrules rules let
letyou
youformat
format the
the top
top (or
(or bottom)
bottom) xx items
items (or
(or xx percent
percentof
of
items), where you can choose x. For example, you can format
items), where you can choose x. For example, you can format the maximum the maximum
number in
number inaa list
list by
by specifying
specifyingthe
the top
top11 item.
item.

TheData
The DataBars,
Bars, Color
Color Scales,
Scales, and
and Icon
Icon Sets
Sets are
areamazing
amazing (and
(and can
can be
beoverdone).
overdone).
The point of all of them is to differentiate levels of values, such as salaries
The point of all of them is to differentiate levels of values, such as salaries or or sales
sales
values.
values.
Tryit!
Try it! Use
Useany
anyinteresting
interesting formats
formats you
youlike
like to
toformat
format the
thedates,
dates, text,
text, or
or numbers
numbers
to the right. Remember that you can always modify the formats or
to the right. Remember that you can always modify the formats or clear them. clear them.

Scroll down for more below

Building Your
Building Your Own
OwnConditional
Conditional Formatting
Formatting Rules
Rules with
with Formulas
Formulas

Youcan
You can get
get even
even more
more control
control by
by building
building your
your own
own rules.
rules.You
Youdo
do this
this by
by clicking
clicking
Conditional Formatting
Conditional Formatting and
and then
then New
New Rule.
Rule. The
The resulting
resultingdialog
dialog box
boxhas
has more
more
optionsthan
options thancan
canbe be explained
explained here,
here, but
but the
the following
followingexplains
explains one
one typical
typical and
and
useful possibility.
useful possibility.
Thedata
The dataset
settoto the
the right
right contains
contains monthly
monthlysales
sales data
data for
for six
sixregions.
regions.Actually,
Actually, they
they
have been
have been entered
entered as asrandom
random numbers
numbers withwiththethe RANDBETWEEN
RANDBETWEEN function,
function,soso ifif
you press
you pressthe
the F9
F9 key,
key, they
they will
will all
all change
change in in aa random
randomway. way. (This
(Thismakes
makes the
the
example even
example even more
moreimpressive!)
impressive!) Suppose
Supposeyou youwant
want toto color
color the
the maximum
maximum sales
sales
valuein
value ineach
each column
columngreen.
green. One
One waywayisisto
to do
do itit separately
separately for for each
each column,
column,
formatting the
formatting the top
top11 item
item as
as explained
explained above.
above. However,
However, thisthis takes
takes too
too much
much time,
time,
especially if there were many more columns. Here
especially if there were many more columns. Here is a better way.is a better way.

1.Starting
1. Startingat
atthe
the darker
darker red
red cell,
cell, drag
dragtoto select
select the
the entire
entire red
redrange.
range.
2.Choose
2. Choose New
New Rule
Rule from
fromConditional
Conditional Formatting,
Formatting, andand select
select "Use
"Use aa formula
formula to
to
determine which cells to format".
determine which cells to format".
3.In
3. In the
the"Format
"Format values
values where
where this
thisformula
formulaisistrue:"
true:"box,
box, enter
enter the
the formula
formula
=(L76=MAX(L$76:L$87)). Then
=(L76=MAX(L$76:L$87)). Thenselect
select aa green
greenformat
format ofof your
your choice.
choice.

Tryit!
Try it! Apply
Applythe
the above
above steps
steps to
tothe
the sales
sales data.
data. Apply
Applyaa similar
similar formula
formulatoto format
format
theminimum
the minimum value
valuein
in each
each column
column red.
red. Then
Then press
press the
theF9
F9key
keyaa few
few times
times and
and
watch how
watch how the
the green
green and
and red
red cells
cells bounce
bounce around.
around.

Once you understand how this formula works, you can do some pretty amazing
1.Starting
1. Startingat
atthe
the darker
darker redred cell,
cell, drag
dragto
to select
select the
the entire
entire red
redrange.
range.
2.Choose
2. Choose New
New Rule
Rule from
fromConditional
Conditional Formatting,
Formatting, andand select
select "Use
"Use aa formula
formula to
to
determinewhich
determine which cells
cells to
to format".
format".
3.In
3. In the
the"Format
"Format values
values where
where this
thisformula
formulaisistrue:"
true:"box,
box, enter
enter the
the formula
formula
=(L76=MAX(L$76:L$87)). Then
=(L76=MAX(L$76:L$87)). Thenselect
select aa green
greenformat
format ofof your
your choice.
choice.

Tryit!
Try it! Apply
Applythe
the above
above steps
steps to
tothe
the sales
sales data.
data. Apply
Applyaa similar
similar formula
formulatoto format
format
the minimum value in each column red. Then press the F9 key a
the minimum value in each column red. Then press the F9 key a few times and few times and
watch how
watch how the
the green
green and
and red
red cells
cells bounce
bounce around.
around.

Once you
Once you understand
understand how how thisthisformula
formula works,
works, you you can
can dodo some
some pretty
pretty amazing
amazing
conditional formatting. Remember that you selected the
conditional formatting. Remember that you selected the entire sales range, but entire sales range, but
L76 isis the
L76 the active
active cell
cell (because
(becauseyou you started
startedthe the dragging
dragging from
from it).
it).The
The formula
formula as as
writtenapplies
written applies to tocell
cell L76.
L76. Specifically,
Specifically, ifif its
its value
valueisis the
themaximum
maximum valuevalue in in
columnL,L, itit isis formatted
column formatted green.
green.But Butbecause
because the the entire
entire sales
sales range
range isis selected,
selected,
the formula is applied, in a relative sense, to each cell in
the formula is applied, in a relative sense, to each cell in the range. The rows the range. The rows in
in
theMAX
the MAX function
function are are made
made absolute
absolute because
because the the maximum
maximum isis always
always over
over these
these
rows, but
rows, butthe
the columns
columns in in the
theMAX
MAX function
function are are made
made relative
relative because
because you you want
want
this formula
this formula to toapply
apply toto all
all cells
cells in
in all
all columns.
columns.
Exam score Cutoffs for extremes
62 High 94
88 Low 66
77
62
94
68
73
61
99
94
88
82
87
65
82
70
94
80
96

Person Birthdate Gender State Children Salary


1 8/5/1959 Male Indiana 1 $65,400
2 10/15/1977 Female Michigan 2 $62,000
3 1/3/1981 Male Illinois 0 $63,200
4 5/5/1949 Male Wisconsin 2 $52,000
5 4/4/1987 Female Michigan 3 $81,400
6 6/30/1949 Female Wisconsin 3 $46,300
7 5/22/1949 Female Ohio 2 $49,600
8 10/30/1952 Male Ohio 1 $45,900
9 1/17/1957 Male Illinois 3 $47,700
10 9/18/1985 Female Indiana 1 $59,900
11 7/19/1953 Male Illinois 1 $48,100
12 12/10/1946 Female Michigan 0 $58,100
13 3/29/1986 Female Wisconsin 2 $56,000
14 12/12/1952 Female Illinois 2 $53,400
15 6/12/1977 Female Illinois 2 $39,000
16 11/19/1989 Male Ohio 1 $61,500
17 9/6/1957 Male Ohio 0 $37,700
18 9/30/1970 Female Michigan 2 $36,700
19 10/24/1973 Male Illinois 2 $45,200
20 6/8/1978 Male Ohio 0 $59,000
21 8/27/1990 Female Ohio 2 $54,300
22 2/9/1947 Male Illinois 1 $62,100
23 4/1/1989 Male Wisconsin 0 $78,000
24 3/12/1970 Male Ohio 0 $43,200
25 3/28/1970 Male Indiana 1 $44,500
26 5/6/1963 Male Michigan 1 $43,300
27 5/7/1959 Male Ohio 3 $45,400
28 3/6/1987 Male Indiana 2 $53,900
29 2/9/1958 Male Michigan 1 $44,100
30 8/4/1955 Female Indiana 2 $31,000

Month Region1 Region2 Region3 Region4 Region5 Region6


Jan-09 $1,416 $4,507 $4,189 $4,818 $1,204 $1,241
Feb-09 $1,594 $3,994 $4,018 $2,709 $2,833 $1,235
Mar-09 $4,006 $1,618 $1,362 $4,395 $1,854 $3,396
Apr-09 $2,986 $2,150 $3,355 $4,144 $2,470 $1,644
May-09 $1,156 $4,152 $4,539 $2,633 $1,712 $3,748
Jun-09 $4,688 $4,374 $2,982 $1,586 $4,425 $3,165
Jul-09 $3,319 $1,509 $2,845 $4,171 $3,308 $4,778
Aug-09 $4,542 $2,669 $4,674 $4,437 $4,820 $1,310
Sep-09 $1,337 $1,064 $2,843 $2,310 $2,223 $1,419
Oct-09 $3,168 $1,679 $2,073 $2,972 $2,876 $1,789
Nov-09 $4,783 $2,905 $2,072 $2,707 $2,341 $4,411
Dec-09 $3,863 $1,870 $3,979 $2,201 $3,532 $3,419
Introduction to
Introduction to Data
Data Validation
Validation

At some
At some point,
point, you
you might
mightbe be developing
developing spreadsheets
spreadsheets for for others
others toto use,
use, and
and you
you
might want to force them to use certain values in certain
might want to force them to use certain values in certain cells because othercells because other
values wouldn't
values wouldn't make makesense
senseor or wouldn't
wouldn't satisfy
satisfybusiness
business rules.
rules.You
Youcancando
do this
this
fairly easily
fairly easilywithwith data
data validation.
validation.There
There are
are actually
actuallymany,
many, many
many possibilities,
possibilities, but
but
only the
only themost
mostcommon
commonare areillustrated
illustrated here.
here. All
All of
of the
theoptions
options areare found
foundfrom
fromthethe
Data Validation item on the Data Validation dropdown on
Data Validation item on the Data Validation dropdown on the Data ribbon. This the Data ribbon. This
leadsto
leads to aa fairly
fairly self-explanatory
self-explanatorydialogdialogbox
box(see
(see totothe
the right).
right). All
All of
of the
theexamples
examples
below assume
below assume you you have
have selected
selected thethecell
cell you
you want
wantto to validate,
validate, and
andthey
they assume
assume
that you
that you have
have opened
opened thisthis dialog
dialogbox
boxand
and have
havechosen
chosen the theSettings
Settings tab.
tab.

Applying aa Simple
Applying Simple Numerical
Numerical Validation
Validation

To allow
To allow only
onlyvalues
values between
between two
two given
given values:
values:

ChooseWhole
Choose Whole Number
Number (if(if you
youwant
want only
onlyintegers)
integers) or
or Decimal
Decimal inin the
the Allow
Allow
dropdown list,
dropdown list, choose
choose Between
Between from
from the
the resulting
resulting Data
Data dropdown,
dropdown, and and enter
enter
values in the Min and Max boxes. You can also place cell references
values in the Min and Max boxes. You can also place cell references in the Min in the Min
andMax
and Maxboxes.
boxes. YouYou can
can experiment
experiment with
with the
the other
other options
optionsin inthe
the Data
Data
dropdown. They
dropdown. They are
are all
all quite
quite straightforward.
straightforward.

TheData
The DataValidation
Validation dialog
dialog box
box has
has two
twoother
other tabs,
tabs, Input
Input Message
Messageand
and Error
Error Alert.
Alert.
Thefirst
The firstallows
allows you
you toto create
create aamessage
message that
that the
theuser
user sees
sees when
whenthe
thecell
cell isis
selected.The
selected. The second
second allows
allows you
youtoto create
create aamessage
message that
that appears
appears ififan
an incorrect
incorrect
valueisisentered
value entered inin the
the cell.
cell.

Tryit!
Try it! Force
Force the
thevalues
valuesin inthe
theblue
bluecells
cells to
to the
theright
right to
to have
have values
values indicated
indicatedbyby
thelabels
the labels to
totheir
their right.
right. Add
Add your
your own
owninput
input messages
messagesand and error
error alerts.
alerts. Then
Thentry
try
entering some
entering someappropriate
appropriateand and inappropriate
inappropriate values
values inin the
theblue
blue cells.
cells.

Validating from
Validating from aa List
List

Probably the
Probably the easiest
easiest data
data validation
validationisis to
to allow
allow the
the user
user to to choose
choose from
from aa
dropdown list of values. To do this, first create the list somewhere,
dropdown list of values. To do this, first create the list somewhere, usually usually out
out of
of
sight to
sight to the
thefar
far right.
right.Then
Then from
from the
the Allow
Allow dropdown
dropdown in in the
theData
DataValidation
Validation dialog
dialog
box, select
box, select List,
List, and
andinin the
theSource
Sourcebox,
box, provide
provide aa cell
cell reference
reference totothe
the list.
list. That's
That's
all you
all youneed
needto to do.
do.When
Whenthe the user
user selects
selects the
thecell
cell to
to be
bevalidated,
validated, aa dropdown
dropdown
arrow automatically
arrow automatically appears,
appears, with
with the
the values
valuesininthe
thelistlistto
to choose
choose from.
from.

Tryit!
Try it! The
The example
example to to the
the right
rightlets
lets aauser
user enter
enter an
an amount
amount to tobe
be financed,
financed, anan
annual interest
annual interestrate,
rate, and
and aaterm
term(number
(number of of months
months to to pay),
pay), and
anditit returns
returns the
the
monthlypayment
monthly payment (using
(usingthe
the PMT
PMT function
function that
thathas
has already
alreadybeen
beenentered).
entered).Create
Create
aa list
listout
out toto the
the right
right somewhere
somewherethat thatcontains
contains the
the possible
possible terms:
terms: 12,12, 24,
24, 36,
36, 48,
48,
and60,
and 60, and
andthenthencreate
createaa data
data validation
validationforfor the
theterm
term cell
cell that
that lets
lets the
theuser
user
choose from
choose from these
these values.
values. Check
Checkthat
thatititworks.
works.
arrow automatically
arrow automatically appears,
appears, with
with the
the values
valuesin
inthe
thelist
listto
to choose
choose from.
from.

Tryit!
Try it! The
The example
example to to the
the right
rightlets
lets aauser
user enter
enter an
an amount
amount to tobe
be financed,
financed, anan
annual interest
annual interestrate,
rate, and
and aaterm
term(number
(number of of months
months to to pay),
pay), and
anditit returns
returns the
the
monthlypayment
monthly payment (using
(usingthe
the PMT
PMT function
function that
thathas
has already
alreadybeen
beenentered).
entered).Create
Create
a list out to the right somewhere that contains the possible terms:
a list out to the right somewhere that contains the possible terms: 12, 24, 36, 48, 12, 24, 36, 48,
and60,
and 60, and
andthen
thencreate
createaa data
data validation
validationforfor the
theterm
term cell
cell that
that lets
lets the
theuser
user
choose from
choose from these
these values.
values. Check
Checkthat
thatititworks.
works.

Validating aa Date
Validating Date

Suppose you
Suppose you wantwanttoto make
make sure
sure the
the person
person enters
enters aavalid
valid date
date inin aacell.
cell.This
This isis aa
great place
great place forfor data
datavalidation.
validation.By
By choosing
choosing the
theDate
Date option
option from
from thethe Allow
Allow
dropdown list,
dropdown list, you
youcan
canforce
forceusers
users toto enter
enter only
onlyvalues
values that
that are
are recognized
recognized as as
dates. This
dates. This isis no
no small
small achievement!
achievement!
In addition,
In addition, you
you can
can put
put limits
limits on
on thethe dates.
dates.ForFor example,
example, suppose
suppose you
you want
wantthethe
person to enter the date he took out a loan. This must not only be a date, but itit
person to enter the date he took out a loan. This must not only be a date, but
can't be
can't bein
inthe
the future.
future. To
To allow
allow only
onlysuch
suchdates,
dates, you
youcan
canselect
select"less
"less than
thanoror equal
equal
to" from
to" from the
the Data
Datadropdown
dropdown and and then
then enter
enter the
thefollowing
following formula
formula ininthe
the End
End
date box:
date box: =TODAY().
=TODAY(). TheThe effect
effect isis that
that the
the user
user will
will not
not be
be allowed
allowed to
toenter
enter aa
future date, regardless of today's
future date, regardless of today's date. date.

Tryit!
Try it! Create
Createthe
thedate
date validation
validationjust
just described
described inin the
the green
green cell
cell to
to the
theright.
right. Then
Then
enter incorrect
enter incorrect and
and correct
correct entries
entries to
to see
see how
how itit works.
works. (Can
(Can you
you change
change itit so
so that
that
only dates at least a week ago are allowed? Just change the formula
only dates at least a week ago are allowed? Just change the formula slightly.) slightly.)
any integer between 1 and 10
any decimal number between 1 and 10
any positive integer
any negative decimal number
any integer between the two values below (which could change)
30 40

Amount financed $25,000


Interest rate 6.25%
Term
Monthy payment #NUM!

Date of loan
Protecting aa Worksheet
Protecting Worksheet or
or Workbook
Workbook

IfIf you
youare
are creating
creating an
anExcel
Excel file
filefor
for others
others to
to use,
use, you
you probably
probably don't
don't want
want them
them
to mess up the formulas you entered so carefully. In fact, you might
to mess up the formulas you entered so carefully. In fact, you might not even not even
want them
want them to to be
be able
able to
to see
see the
the formulas
formulas(company
(company secrets?).
secrets?). Excel
Excel gives
givesyou
you
plenty of
plenty of options
options for
for protecting
protecting (or(or unprotecting)
unprotecting) your
your work.
work.Only
Only aafew
few of
of them
them
areexplained
are explainedhere.
here. You
You can
can then
then experiment
experiment with
withothers.
others.

Thekey
The keyidea
idea isis locking
locking cells.
cells.Right-click
Right-click any
anycell
cell on
onthis
this sheet,
sheet, select
select Format
FormatCells,
Cells,
andclick
and click the
the Protection
Protection tab.
tab. You
You will
will see
see that
that the
theLocked
Locked option
option isis checked.
checked.By By
default, all
default, all cells
cells are
are locked
lockeduntil
until you
youunlock
unlockthem.
them.But But this
thislocking
locking has
has no
no effect
effect
until you
until you protect
protect thetheworksheet
worksheet(or (or the
theworkbook).
workbook). Therefore,
Therefore, protecting
protecting isis aa
two-step process.
two-step process.

1.Unlock
1. Unlockall
all cells
cells you
youwant
want users
usersto
to have
have access
access to.
to. These
These are
are typically
typically"input"
"input"
cells where a user can enter data like unit cost, amount ordered, and
cells where a user can enter data like unit cost, amount ordered, and so on.so on.

2.Protect
2. Protectthethe worksheet
worksheet (or (or workbook).
workbook). To To do
do this,
this, select
selectProtect
Protect Sheet
Sheet (or
(or
Protect Workbook)
Protect Workbook) from fromthethe Review
Review ribbon.
ribbon. ForFor example,
example,whenwhen you
you select
select
Protect Sheet,
Protect Sheet, you
youseesee the
the dialog
dialog box
box to
tothe
the right.
right.You
You clearly
clearlyhave
haveaa lot
lot of
of
optionsfor
options for what
what youyou want
wanttoto allow
allow users
users toto do.
do. For
For example,
example, with
with the
the settings
settings
shown, users
shown, users will
will be
be allowed
allowed toto select
select locked
lockedcells
cells but
but not
not modify
modify them.
them. IfIf the
the
"Select locked
"Select lockedcells"
cells" were
were unchecked,
unchecked, usersusers wouldn't
wouldn'teveneven bebe allowed
allowed to to select
select
locked cells,
locked cells, so
so any
any formulas
formulasin inthese
these cells
cells would
wouldbe be hidden.
hidden. Note
Note that
that you
you cancan
also add
also add aa password
passwordwhen whenyouyou protect
protectaa worksheet
worksheet or or workbook.
workbook. Just
Just be
becareful
careful
to remember
to remember it. it. Otherwise,
Otherwise, youyouwon't
won't be be able
ableto to unprotect
unprotect (and
(and then
then modify)
modify)
your own
your ownwork!
work!
Creating aa User
Creating
When you
When
User Interface

youfill
Interface with

fill out
outan
with Simple

an online
Simple Form
Form Controls
Controls

onlinequestionnaire,
questionnaire, or or when
whenyou
you work
work with
with almost
almost any
any
Pr..
Windows program, you continually see "controls" such as radio buttons,
Windows program, you continually see "controls" such as radio buttons, check check
boxes, text
boxes, text boxes,
boxes, buttons,
buttons, dropdown
dropdown lists,
lists, and
and others.
others.You
Youprobably
probably don't
don'teven
even
think about
think about how
how these
these work
work because
becauseyou
you see
see them
them so
so often.
often.

Thegood
The good news
news ititisis that
thatyou
youcancanaddaddsuch
suchcontrols
controls to
to Excel
Excel worksheets,
worksheets, and and itit isis
remarkably easy,
remarkably easy, with
with no noprogramming
programming required.
required.The
Thefirst
firstthing
thing you
you should
should do do isis
make the
make the Developer
Developer ribbonribbon visible.
visible.ToTo dodo this
thisin
inExcel
Excel 2007,
2007, click
click the
the Office
Office
button, then
button, then Excel
Excel Options,
Options, andand check
check thethethird
thirdcheck
check box
boxinin the
thePopular
Popular group.
group.
(See the Add-ins Buttons worksheet in this tutorial for doing this
(See the Add-ins Buttons worksheet in this tutorial for doing this in Excel 2010.) in Excel 2010.)
Once the
Once theDeveloper
Developer ribbonribbon isis visible,
visible, click
click the
the Insert
Insert dropdown
dropdownto to see
see the
the list
listof
of
controls shown
controls shown toto the
theright.
right. There
Thereareare two
two groups,
groups, the
the "easy"
"easy" Forms
Forms controls
controlsand and
the"advanced"
the "advanced" ActiveX
ActiveX controls.
controls. TheThe latter
latter require
require some
someprogramming,
programming, so so only
only
the Forms controls are discussed
the Forms controls are discussed here. here.

To insert
To insertany
any of
of these
these controls
controls on
onaa worksheet,
worksheet, click
click the
the control
control and
and then
then drag
drag itit
where you
where you want
wantit.it. The
Thecontrol
control comes
comes alive
aliveknowing
knowing thethe behavior
behavior ititought
oughtto
to
have. For example, radio (bulls-eye) buttons know that only one of
have. For example, radio (bulls-eye) buttons know that only one of them can bethem can be
checked, whereas
checked, whereas check
check boxes
boxes know
know that
that any
anynumber
number of of them
themcan
can be be checked.
checked.

Theapplication
The application has
hasalready
already been
been created,
created, using
using the
the following
followingsteps.
steps.

1.Create
1. Createthethe frame
frameat at the
the top
top(by
(by clicking
clicking the
the Group
GroupBoxBox Form
Form Control
Control and
and
dragging itit to
dragging to aa desired
desired location),
location), and
andchange
changeitsits label
label to
to Product
Product purchased.
purchased.

2.Insert
2. Insert three
three radio
radio buttons
buttons inside
inside the
the frame
frame (by
(byclicking
clicking the
theOption
Option Button
ButtonForm
Form
Control and
Control andthen
then dragging
dragging them
them inside
inside the
the frame),
frame), and
andchange
change their
their labels
labels to
to the
the
product names.
product names.

3.Insert
3. Insert aacheck
check box
box (outside
(outside of
of the
the frame)
frame) for
for preferred
preferred customers.
customers.

4.At
4. At this
this point,
point, these
these radio
radio buttons
buttons and
andthethe check
check boxboxaren't
aren't yet
yetfunctional.
functional. ToTo
make them
make them functional,
functional, right-click
right-click any
any one
one of
of the
theradio
radio buttons
buttons and
and select
select Format
Format
Control. You
Control. You will
will see
seeaa Control
Control tab
tabwith
with aaCell
Cell link
link box.
box.Select
Select aacell
cell out
outofof view,
view,
suchas
such as AA1.
AA1.Then
Then depending
depending on onwhich
which radio
radio button
button isis selected,
selected, cell
cell AA1
AA1 will
will
contain1,
contain 1, 2,
2, or
or 3.
3. Again,
Again, you
you need
need to
to do
do this
this for
for only
only one
one of
of the
the radio
radio buttons.
buttons.
Theothers
The others will
will automatically
automaticallyhave havethe
thesame
sameCellCell link.
link.Similarly,
Similarly, create
createaa Cell
Cell link
link
for the check box to a cell such as AA2. Depending on whether the checkbox isis
for the check box to a cell such as AA2. Depending on whether the checkbox
checked, cell
checked, cellAA2
AA2will
will contain
contain TRUE
TRUE or
or FALSE.
FALSE.

5.Create
5. Createformulas
formulas in
inthe
the blue
blue cells
cells that
that refer
refer to
to these
thesecell
cell links
links (which
(whichhas
has
already been done).
already been done).
Now try
Now trycreating
creating this
thisapplication
applicationyourself.
yourself.
Pr... Flat-screen TV
Prices
Flat-screen TV $2,500
Blu-ray disc player $450
Blu-ray disc player Laptop computer $650

Laptop computer
Preferred discount 5%

Preferred customer

Invoice
Product Blu-ray disc player
Price $450
Discount $23
Net price $428
2

1
Backgraound for
Backgraound for Macros
Macros and
and VBA
VBA Programming
Programming in
in Excel
Excel

IfIf you
you want
want even
even more
more power
power in in Excel,
Excel, you
you can
canautomate
automatejust just about
about any
any task
task with
with
a macro. Macros are written in the programming language for
a macro. Macros are written in the programming language for Excel and the rest Excel and the rest
of Office,
of Office, called
called Visual
Visual Basic
Basic for
for Applications
Applications (VBA).
(VBA).VBA
VBA isis aa relatively
relatively easy
easy
programming language
programming languageto to learn,
learn, but
butititdoes
does take
take some
somestudy
study and andaa lot
lot of
ofpractice.
practice.
(If you
(If you are
areinterested,
interested, check
check out
out the
the VBA
VBA for
forModelers
Modelers book
book at at
http://www.kelley.iu.edu/albrightbooks.)
http://www.kelley.iu.edu/albrightbooks.)
Even ifif you
Even you know
know nothing
nothing about
about programming,
programming, youyou can
canstill
still record
record macros
macrostoto
perform some
perform somesimple
simpletasks.
tasks. You
You can
can then
then create
create buttons
buttons to
to run
run these
these macros
macros and
and
place them on the QAT so that they are always available to you. There
place them on the QAT so that they are always available to you. There are several are several
things you
things you should
should know
know before
before you
you start
start working
working with
with macros:
macros:

1.There
1. There isis aaDeveloper
Developer tab
taband
and ribbon
ribbonyou
youshould
should make
make visible
visible(see
(see to
to the
the right).
right).
This has various buttons for working with macros. To make it visible
This has various buttons for working with macros. To make it visible in Excel 2007,in Excel 2007,
open the
open theExcel
Excel Options
Options dialog
dialogbox.
box.Under
Under thethe Popular
Popular group,
group, check
check the
the third
third
option: Show
option: Show Developer
Developer tabtab in
in the
the Ribbon.
Ribbon.OnceOnce you
you check
check this
this option,
option, the
the
Developer tab
Developer tab will
will always
alwaysbe be visible.
visible. (See
(See the
the Add-ins
Add-ins buttons
buttons worksheet
worksheet in in this
this
tutorial for how to do this in Excel
tutorial for how to do this in Excel 2010.) 2010.)

2.Files
2. Files in
in Excel
Excel 2007
2007 and
and more
morerecent
recent versions
versions that
that contain
containmacros
macros must
must have
havethe
the
.xlsmextension
.xlsm extension("m"("m" for
for macro).
macro).IfIf you
youtry
try to
to save
savesuch
suchaa file
file as
asan
an .xlsx
.xlsx file,
file, you
you
won'tbe
won't be allowed
allowedtoto do
do so.
so.

3.There
3. There isis aaspecial
special file,
file, Personal.xlsb,
Personal.xlsb, that
that you
youwill
will probably
probably want
wantto to record
record your
your
macros to.
macros to. This
This file
fileopens
opens automatically
automatically asas aa hidden
hidden file
file whenever
whenever you
you open
open
Excel. Therefore,
Excel. Therefore, all all of
of its
its macros
macros are
arealways
always available,
available, regardless
regardless of
of what
what other
other
Excel files
Excel files are
areopen.
open.

4.IfIf you
4. youwant
want totowrite
write your
your own
ownmacros,
macros, or
or ifif you
you want
wantto to look
look at
atrecorded
recorded
macros, you need to go to the VB Editor. You can do this
macros, you need to go to the VB Editor. You can do this from the Visual from the Visual Basic
Basic
button on
button on the
the Developer
Developer tab,tab, or
or more
moreeasily,
easily, with
with the
theAlt+F11
Alt+F11 keyboard
keyboard shortcut.
shortcut.
Try itit now.
Try now. Press
Press Alt+F11.
Alt+F11. This
This opens
opens aanew
new window.
window. When When you you are
arefinished
finished
looking around,
looking around, youyou can
can close
close this
this window.
window. Excel
Excel will
will still
still be
beopen.
open.

Recording aa Macro
Recording Macro

Now let's
Now let's record
record aamacro
macro and
and then
then try
try itit out.
out. This
This will
will be
beaa very
very simple
simplemacro
macro that
that
formatsthe
formats the selected
selected cell(s)
cell(s) as
as integers,
integers, that
thatis,
is, as
asNumber
Number with
withzero
zero decimals.
decimals.

1.Make
1. Make the
the Developer
Developer ribbon
ribbonvisible
visible(see
(see above),
above), ifif necessary.
necessary. Select
Selectanyanyrange
range
such as
such as the
the numbers
numbers below
below and
and to
to the
the right
rightin
incolumn
column K,K, and
andclick
click the
the Record
Record
Macro button
Macro buttononon the
theDeveloper
Developer ribbon.
ribbon.ThisThis turns
turns the
therecorder
recorder on.
on. ItItwill
will record
record
everything you
everything you do
dountil
until you
youturn
turnthe
therecorder
recorder off.
off.

2.When
2. When youyouclick
click the
the Record
Record Macro
Macro button,
button, you
you will
will see
seethe
thedialog
dialog box
boxtoto the
the
right.Fill
right. Fill ititout
out as
as shown
shown andandclick
click OK.
OK.YouYoucan
can give
giveitit aa meaningful
meaningful namename (no
(no
spaces), and
spaces), andyouyoucan
canspecify
specifywhere
where itit should
shouldbe be stored.
stored.The The choice
choice shown
shown here
here isis
the Personal Macro Workbook, which is the same as the
the Personal Macro Workbook, which is the same as the Personal.xlsb filePersonal.xlsb file
mentioned above.
mentioned above.This
This will
will make
make the
the macro
macro available
available atat all
all times.
times.
1.Make
1. Make the
the Developer
Developer ribbon
ribbonvisible
visible(see
(see above),
above), ifif necessary.
necessary. Select
Selectanyanyrange
range
such as the numbers below and to the right in column K, and click
such as the numbers below and to the right in column K, and click the Recordthe Record
Macro button
Macro buttonon on the
theDeveloper
Developer ribbon.
ribbon.This
This turns
turns the
therecorder
recorder on.
on. ItItwill
will record
record
everything you
everything you do
dountil
until you
youturn
turnthe
therecorder
recorder off.
off.

2.When
2. When youyouclick
click the
the Record
Record Macro
Macro button,
button, youyou will
will see
seethe
thedialog
dialog box
boxtoto the
the
right.Fill
right. Fill ititout
out as
as shown
shown andandclick
click OK.
OK.YouYoucan
can give
giveitit aa meaningful
meaningful namename (no
(no
spaces), and
spaces), andyouyoucan
canspecify
specifywhere
where itit should
shouldbe be stored.
stored.The The choice
choice shown
shown here
here isis
thePersonal
the Personal Macro
Macro Workbook,
Workbook, which
which isis the
the same
same asasthethe Personal.xlsb
Personal.xlsbfile
file
mentioned above.
mentioned above.This
This will
will make
make the
the macro
macro available
available at at all
all times.
times.

3.Now
3. Now perform
performthe
the task
task you
you want
want to
to record.
record. In
Inthis
this case,
case, format
format the
theselected
selected
range as
range asNumber
Number with
with zero
zero decimals.
decimals.

4.From
4. From the
the Developer
Developer ribbon,
ribbon, click
click the
the Stop
StopRecording
Recording button.
button.

5.Although
5. Although this
this isis not
notnecessary,
necessary, ifif you
youwant
want toto see
see the
therecorded
recordedmcaro,
mcaro, press
press
Alt-F11 and look at the module(s) under Personal on the left side
Alt-F11 and look at the module(s) under Personal on the left side of the VB Editor. of the VB Editor.
(Modules are
(Modules are where
where macrosmacros are
are stored.)
stored.) Even
Even ifif you
you know
know nothing
nothing about
about
programming or
programming or VBA,
VBA, thetherecorded
recordedcode codeprobably
probably makes
makes sense.
sense.With
With some
some
experience, you
experience, you cancan modify
modify this
this code
codeto to suit
suit your
your exact
exact needs.
needs.ForFor now,
now, though,
though,
you can leave it as is; it works
you can leave it as is; it works fine.fine.

6.Now
6. Now you
youhave
have aa nice
nice macro,
macro, but
but you
you need
need aa button
buttonto to run
run it.
it. To
To create
create suchsuch aa
button, click
button, clickthe
the dropdown
dropdown arrowarrownext
next to
to the
theQAT,
QAT, and
andthen
then More
More Commands
Commands to to
bring up the Customize dialog box. Under the "Choose
bring up the Customize dialog box. Under the "Choose commands from" commands from"
dropdown, choose
dropdown, choose Macros.
Macros.(See
(See toto the
theright.)
right.) Select
Select your
your IntegerFormat
IntegerFormatmacro macro
from the
from the resulting
resultinglist,
list, and
and click
click the
theAdd>>
Add>> button
button to to create
createaa button
button forfor ititon
on the
the
QAT.The
QAT. The button
button will
will have
haveaa generic
generic icon,
icon, but
but ifif you
you click
click the
the Modify
Modifybutton,
button, you
you
can choose
can choose aamore
more appealing
appealing icon.
icon.

7.Now
7. Now that
thatyou
youhavehave aa nice
nice button
button on
onyour
your QAT,
QAT, try
tryititout.
out. Select
Select the
thetwo
two
numeric cells
numeric cells to
to the
the right
rightin
in column
column M M and
andclick
click your
your button.
button. They
They should
should be
be
reformatted.
reformatted.
Notethat
Note that you you were
were asked
askedto to select
select aarange
range before
before recording
recording the
the macro.
macro. TheThe
reason isis that
reason that the
themacro
macrowill
willthen
then apply
apply to
to whatever
whatever range
range isis selected.
selected. IfIf you
you
began recording and then selected a range such as K72:K74, your
began recording and then selected a range such as K72:K74, your macro would macro would
work only
work onlyfor for this
thisspecific
specific range.
range.

Helpful tip:
Helpful tip: There
There isis aahandy
handy"Record
"Record macro"
macro" button
button at
atthe
the bottom
bottom left
leftof
of your
your
Excel window. If you are currently recording a macro, this button becomes aa "Stop
Excel window. If you are currently recording a macro, this button becomes "Stop
recording" button.
recording" button.So So the
the Developer
Developer tab
tab isn't
isn't really
really necessary
necessary after
after all.
all.
2.0001 50.0001
30.9999 0.9999
-3.0002

Vous aimerez peut-être aussi