Download presentation
Presentation is loading. Please wait.
Published byRhoda Stevenson Modified over 8 years ago
1
Hoi Le
2
COUNTIF Countif(, ) Return number of elements that meet the criteria Always put criteria in quotation marks Example 1: count number of employees in IT department. Hoi Le2
3
COUNTIF (Cont’d) Example 2: Return number of employees that have salary greater than Reagan’s salary “&” operator: concatenate two strings Hoi Le3
4
Note: General form of a function: function_name( ) Parameters are separated by “,” mark E.g.: sum(B2:B10), count(B2:B10), countif(B2:B10,”IT”) Hoi Le4
5
SUMIF Similar to the Countif function Return the sum of values that satisfy the condition Example: return sum of salaries greater than 15000 Hoi Le5
6
SUMIF (Cont’d) Second usage of Sumif: First range of cells: to check the condition Followed by the criteria Second range of cells: to sum up Example: return sum of salaries of employees in IT department. Hoi Le6
7
Note: Comparison operators: >, =,, = Hoi Le7
8
IF Syntax: If(logical_test, value_if_true, value_if_false) Example: Grade>=60: passed Grade<60: failed Hoi Le8
9
Nested If Hoi Le9
10
Nested If (Cont’d) To solve above problem: use nested If function Nested If: replace the third parameter value_if_false with a new If statement Hoi Le10
11
Nested If (Cont’d) Hoi Le11
12
Lookup Another way to solve that problem: use lookup function First, you need to create a look up table. Must be in ascending order 0<=Grade <50: F 50<=Grade <65: D 65<=Grade <80: C … Hoi Le12
13
Lookup (Cont’d) Hoi Le13
14
Lookup (Cont’d) Use absolute address for lookup table to make it fixed when you copy the formula G2:H6: relative address $G$2:$H$6: absolute address Hoi Le14
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.