Financial analysis often requires evaluating multiple conditions, such as bonus eligibility, loan approval, credit ratings, or tax bracket assignment. Handling these tasks manually can be time-consuming and increase the chances of errors, especially when working with large datasets.
Excel Logical Functions automate these decisions and make financial models more efficient and reliable. The concepts covered here include IF, AND, OR, NOT, IFS and SWITCH with practical finance-based examples for CA, MBA Finance, IB, FM, and B.Com learners.
Logical Functions in Excel help check whether a condition is true or false and return the required result. They are widely used in financial models to automate calculations and make decisions based on predefined rules. Functions such as IF, AND, OR, NOT, IFS, and SWITCH reduce manual work and improve accuracy. They are useful for tasks like bonus calculations, loan eligibility, credit ratings, tax bracket assignment, and other finance-related decisions.
Logical Functions in Excel help evaluate conditions and return results based on predefined rules. They are widely used in financial modelling to automate calculations, improve decision-making, and reduce manual effort. The concepts covered here include functions for testing conditions, combining multiple criteria, assigning categories, and handling errors in financial data.
|
Overview |
Details |
|
Topic |
Excel Logical Functions for Finance |
|
Main Functions Covered |
IF, AND, OR, NOT, IFS, SWITCH, |
|
Primary Purpose |
Apply conditions and automate logical decisions in Excel |
|
Common Financial Applications |
Bonus calculation, performance ratings, loan eligibility, credit ratings, tax bracket assignment, investment portfolio classification |
|
Who Should Learn It? |
CA, MBA Finance, Investment Banking (IB), Financial Management (FM), and B.Com students |
|
Key Benefit |
Reduces manual work, improves accuracy, and makes financial models easier to manage |
The IF function is one of the most commonly used logical functions in Excel. It checks whether a condition is true or false and returns the appropriate result. Consider an employee bonus assessment where employees receive a bonus only if their sales are greater than the assigned target. The IF function helps identify eligible employees and calculate their bonus automatically.
Bonus Eligibility Rules
Employees qualify for a bonus if Sales > Target.
Qualified employees receive a bonus equal to 10% of Sales.
Employees who do not qualify receive a bonus of 0.
Follow these steps to check employee bonus eligibility using the IF function. First, compare each employee's sales with the assigned target. Then use the result to calculate the bonus amount automatically.
Begin by entering the IF function. The logical test compares an employee's Sales with the Target. If the sales value is greater than the target, the employee qualifies for the bonus.
Formula
=IF(Sales>Target,"Yes","No")
If the condition is true, Excel returns "Yes". If the condition is false, it returns "No". Remember to write text values such as "Yes" and "No" inside inverted commas.
After identifying eligible employees, use another IF function to calculate the bonus amount. If the result in G2 is "Yes", Excel calculates 10% of Sales. Otherwise, it returns 0.
Formula
=IF(G2="Yes",0.10*Sales,0)
This formula automatically calculates the bonus amount. Eligible employees receive 10% of Sales, while employees who do not qualify receive 0. The IF function is useful whenever a calculation depends on a single condition.
The table below shows the final output after applying both IF formulas to the employee data.
|
Employee |
Sales ($) |
Target ($) |
Qualified? |
Bonus ($) |
|
Alice |
92,000 |
85,000 |
Yes |
9,200 |
|
Bob |
73,000 |
80,000 |
No |
0 |
|
Carol |
110,000 |
100,000 |
Yes |
11,000 |
|
David |
68,000 |
70,000 |
No |
0 |
|
Eva |
95,000 |
90,000 |
Yes |
9,500 |
|
Frank |
105,000 |
100,000 |
Yes |
10,500 |
|
Grace |
60,000 |
75,000 |
No |
0 |
The output shows which employees qualify for the bonus and the bonus amount calculated automatically using the IF function.
The Nested IF function is useful when there are more than two possible outcomes. Instead of checking only one condition, it evaluates multiple conditions in a specific order and returns the appropriate result. Consider a performance rating exercise where employees are assigned different performance labels based on their rating scores.
Performance Rating Rules
Employees with a rating of 4 or above receive "Excellent".
Employees with a rating of 3 or above but below 4 receive "Good".
Employees with a rating below 3 receive "Needs Improvement".
Follow these steps to assign performance ratings using the Nested IF function. Start by checking the highest rating condition first, then evaluate the remaining conditions in descending order until the correct performance label is assigned.
Begin by checking whether the employee's rating is 4 or above. If this condition is true, Excel returns "Excellent". Otherwise, move to the next condition.
If the first condition is false, check whether the rating is 3 or above. If this condition is true, Excel returns "Good". If neither condition is true, Excel returns "Needs Improvement".
Combine all the conditions into a single Nested IF formula.
Formula
=IF(Rating>=4,"Excellent",IF(Rating>=3,"Good","Needs Improvement"))
Always check the highest condition first and close a bracket for each IF function used.
The table below shows the final performance ratings after applying the Nested IF formula.
|
Employee |
Rating (1ā5) |
Performance Rating |
|
Alice |
4.2 |
Excellent |
|
Bob |
3.1 |
Good |
|
Carol |
4.8 |
Excellent |
|
David |
2.5 |
Needs Improvement |
|
Eva |
3.9 |
Good |
|
Frank |
4.0 |
Excellent |
|
Grace |
2.2 |
Needs Improvement |
The Nested IF function is useful when a formula needs to return more than two possible results based on multiple conditions.
AND, OR, and NOT functions are used when a decision depends on one or more conditions. These functions help finance professionals evaluate loan applications based on factors such as credit score, income, and existing debt. Depending on the business rule, Excel can approve or reject an application automatically.
The AND function returns TRUE only when all conditions are TRUE. If even one condition is FALSE, the result becomes FALSE. This is useful when every eligibility rule must be satisfied before approving a loan.
Credit Score ā„ 700
Income ā„ $50,000
Existing Debt < $20,000
Loan is approved only if all three conditions are met.
Follow these steps to check whether an applicant qualifies for a loan using the AND function. First, verify all eligibility conditions. Then combine the result with the IF function to display the final decision.
Use the AND function to test whether every condition is satisfied.
Formula
=AND(CreditScore>=700,Income>=50000,Debt<20000)
If all conditions are TRUE, Excel returns TRUE. If any one condition is FALSE, Excel returns FALSE.
Wrap the AND function inside an IF function to show the loan decision.
Formula
=IF(AND(CreditScore>=700,Income>=50000,Debt<20000),"Approved","Rejected")
Applicants meeting all conditions are marked Approved. Everyone else is marked Rejected.
The table below shows the final result after applying the AND and IF formulas.
|
Applicant |
Credit Score |
Income ($) |
Debt ($) |
AND Eligible? |
Final Decision |
|
Rahul |
720 |
65,000 |
15,000 |
TRUE |
Approved |
|
Priya |
680 |
90,000 |
25,000 |
FALSE |
Rejected |
|
Amit |
750 |
45,000 |
10,000 |
FALSE |
Rejected |
|
Sunita |
590 |
55,000 |
18,000 |
FALSE |
Rejected |
|
Vikram |
710 |
52,000 |
22,000 |
FALSE |
Rejected |
|
Neha |
800 |
85,000 |
5,000 |
TRUE |
Approved |
|
Ravi |
640 |
48,000 |
30,000 |
FALSE |
Rejected |
The OR function returns TRUE if at least one condition is TRUE. It is useful when meeting any one of the eligibility conditions is enough to approve the application.
Credit Score > 750 OR
Income ā„ $80,000
If either condition is satisfied, the applicant is eligible.
Follow these steps to evaluate loan eligibility using the OR function. Excel checks both conditions and returns TRUE if at least one condition is satisfied.
Use the OR function to test the required conditions.
Formula
=OR(CreditScore>750,Income>=80000)
If either condition is TRUE, Excel returns TRUE. If both conditions are FALSE, Excel returns FALSE.
Use the OR function inside the IF function to show the approval status.
Formula
=IF(OR(CreditScore>750,Income>=80000),"Approved","Rejected")
Applicants satisfying at least one condition are marked Approved. Others are marked Rejected.
The table below shows the final result after applying the OR and IF formulas.
|
Applicant |
Credit Score |
Income ($) |
Debt ($) |
OR Eligible? |
Final Decision |
|
Rahul |
720 |
65,000 |
15,000 |
FALSE |
Rejected |
|
Priya |
680 |
90,000 |
25,000 |
TRUE |
Approved |
|
Amit |
750 |
45,000 |
10,000 |
FALSE |
Rejected |
|
Sunita |
590 |
55,000 |
18,000 |
FALSE |
Rejected |
|
Vikram |
710 |
52,000 |
22,000 |
FALSE |
Rejected |
|
Neha |
800 |
85,000 |
5,000 |
TRUE |
Approved |
|
Ravi |
640 |
48,000 |
30,000 |
FALSE |
Rejected |
The NOT function changes the result of a logical test. If a condition is TRUE, NOT returns FALSE. If the condition is FALSE, NOT returns TRUE. It is useful when you want to reverse a condition before making a decision.
Credit Score < 600 is considered High Risk.
Applicants who are NOT High Risk can be approved.
Follow these steps to reverse the high-risk condition using the NOT function and display the final loan decision.
Use the NOT function to check whether the applicant is not in the high-risk category.
Formula
=NOT(CreditScore<600)
If the credit score is 600 or above, Excel returns TRUE. Otherwise, it returns FALSE.
Combine the NOT function with the IF function.
Formula
=IF(NOT(CreditScore<600),"Approved","Rejected")
Applicants who are not high risk are marked Approved, while high-risk applicants are marked Rejected.
The table below shows the final result after applying the NOT and IF formulas.
|
Applicant |
Credit Score |
Income ($) |
Debt ($) |
NOT Eligible? |
Final Decision |
|
Rahul |
720 |
65,000 |
15,000 |
TRUE |
Approved |
|
Priya |
680 |
90,000 |
25,000 |
TRUE |
Approved |
|
Amit |
750 |
45,000 |
10,000 |
TRUE |
Approved |
|
Sunita |
590 |
55,000 |
18,000 |
FALSE |
Rejected |
|
Vikram |
710 |
52,000 |
22,000 |
TRUE |
Approved |
|
Neha |
800 |
85,000 |
5,000 |
TRUE |
Approved |
|
Ravi |
640 |
48,000 |
30,000 |
TRUE |
Approved |
The IFS and SWITCH functions provide cleaner and more readable alternatives to long Nested IF formulas. While the IFS function evaluates multiple logical conditions in sequence, the SWITCH function matches a value against predefined options. These functions simplify formulas, improve readability, and make them easier to maintain.
The IFS function evaluates multiple conditions one after another and returns the value for the first TRUE condition. It is useful when you need to assign different results based on multiple ranges without creating lengthy Nested IF formulas.
|
Credit Score |
Rating |
|
ā„ 800 |
AAA |
|
ā„ 750 |
AA |
|
ā„ 700 |
A |
|
ā„ 600 |
BB |
|
Below 600 |
B or Below |
The formula is:
=IFS(C2>=800,"AAA",C2>=750,"AA",C2>=700,"A",C2>=600,"BB",TRUE,"B or Below")
Excel evaluates each condition from left to right and returns the result for the first TRUE condition. The final TRUE acts as the default condition, returning "B or Below" whenever none of the previous conditions are satisfied. This makes the formula much easier to read and maintain than a deeply Nested IF formula.
The SWITCH function compares a single value against multiple predefined values and returns the corresponding result. It is useful when working with fixed categories, such as tax bracket codes, grades, status codes, or other predefined labels.
The formula is:
=SWITCH(C20,1,0%,2,5%,3,10%,4,15%,5,20%)
The SWITCH function checks the Bracket Code and returns the corresponding tax rate for the first matching value. Since it matches exact values instead of logical conditions, it provides a cleaner and more concise alternative to writing multiple IF statements for fixed categories.
The tables below show the final output after applying the IFS function to assign credit ratings based on credit scores and the SWITCH function to assign tax rates using bracket codes.
Tax Bracket Rules
|
Taxpayer |
Bracket Code |
Tax Rate % |
|
Ananya |
1 |
0% |
|
Deepak |
3 |
10% |
|
Kavitha |
5 |
20% |
|
Mohan |
2 |
5% |
|
Sreeja |
4 |
15% |
|
Tanvir |
1 |
0% |