Download as pdf or txt
Download as pdf or txt
You are on page 1of 14

Dr.

KHIMYA S TINANI
tinani.khimya-stat@msubaroda.ac.in
B.Sc.(Sem-V)-Data Analysis using Microsoft Excel

Formulas and Functions:


A formula is an expression which calculates the value of a
cell. Functions are predefined formulas and are already
available in Excel.
A function is a preset formula in Excel. Like formulas,
functions begin with the equal sign ( = ) followed by the
function's name and its arguments. The function name tells
Excel what calculation to perform. The arguments are
contained inside round brackets.

For example, cell A3 below contains a formula which adds the


value of cell A2 to the value of cell A1.

Count and Sum Functions:


The most used functions in Excel are the functions
that count and sum. You can count and sum based on
one criteria or multiple criteria.
COUNT:
To count the number of cells that contain numbers, use the
COUNT function.

1
COUNTIF:
To count cells based on one criteria (for example, higher than
9), use the following COUNTIF function.

COUNTIFS:
To count cells based on multiple criteria (for example, green
and higher than 9), use the following COUNTIFS function.

2
Count Blank/Nonblank Cells:
This example shows you how to count the number
of blank and nonblank cells in Excel.
1. The COUNTBLANK function counts the number of blank
cells.

3
2. The COUNTA function counts the number of nonblank cells.
COUNTA stands for count all.

Count Logical Values:


How to count the number of cells that contain logical values
(TRUE and FALSE) in Excel.
1. For example, to count the number of cells that contain
TRUE.

4
2. For example, to count the number of cells that contain
FALSE.

3. For example, to count the number of cells that contain TRUE


or FALSE.

Count Text Occurrences:


This example teaches you how to count the number of
occurrences of text in a range.
5
1. For example, to count the number of cells that contain
exactly star.

2. For example, to count the number of cells that contain


exactly star + 1 character. A question mark (?) matches exactly
one character.

3. For example, to count the number of cells that contain


exactly star + a series of zero or more characters. An asterisk
(*) matches a series of zero or more characters.

6
4. For example, to count the number of cells that contain star in
any way. No matter what is before or after star, this function
finds all the cells that contain star in any way.

5. For example, to count the number of cells that contain text.

7
SUM:
To sum a range of cells, use the SUM function.

SUMIF:
To sum cells based on one criteria (for example, higher than 9),
use the following SUMIF function (two arguments).

8
To sum cells based on one criteria (for example, green), use the
following SUMIF function (three arguments, last argument is
the range to sum).

SUMIFS:
To sum cells based on multiple criteria (for example, blue and
green), use the following SUMIFS function (first argument is
the range to sum).

9
General note: in a similar way, you can use the AVERAGEIF
and AVERAGEIFS function to average cells based on one or
multiple criteria.
SUMPRODUCT:
To calculate the sum of the products of corresponding numbers
in one or more ranges, use Excel's powerful SUMPRODUCT
function.
1. For example, the SUMPRODUCT function below calculates
the total amount spent.

Note: the SUMPRODUCT function performs this calculation:


(2 * 1000) + (4 * 250) + (4 * 100) + (2 * 50) = 3500.
10
2. The ranges must have the same dimensions or Excel will
display the #VALUE! error.

3. The SUMPRODUCT function treats any entries that are not


numeric as if they were zeros.

Round:
There are three functions to round numbers in Excel.
ROUND, ROUNDUP and ROUNDDOWNfunction.
11
1. Round a number to two decimal places.

Note: 1, 2, 3, and 4 get rounded down. 5, 6, 7, 8, and 9 get


rounded up.
2. Round a number to one decimal place.

3. Round a number to the nearest integer.

4. Round a number to the nearest 10.

12
5. Round a number to the nearest 100.

ROUNDUP:
The ROUNDUP function always rounds a number up (away
from zero). For example, round a number up to one decimal
place.

ROUNDDOWN:
The ROUNDDOWN function always rounds a number down
(toward zero). For example, round a number down to the
nearest integer.

13
14

You might also like