Shubham Spreadsheet
Shubham Spreadsheet
Home
Comprises options like font size, font styles, font colour, background
colour, alignment, formatting options and styles, insertion and deletion
of cells and editing options.
Insert
Comprises options like table format and style, inserting images and
figures, adding graphs, charts and sparklines, header and footer option,
equation and symbols.
Page Layout
4
Themes, orientation and page setup options are available under the
page layout option.
Formulas
Since tables with a large amount of data can be created in MS excel,
under this feature, you can add formulas to your table and get quicker
solutions.
Data
Adding external data (from the web), filtering options and data tools
are available under this category.
Review
Proofreading can be done for an excel sheet (like spell check) in the
review category and a reader can add comments in this part.
View
Different views in which we want the spreadsheet to be displayed can
be edited here. Options to zoom in and out and pane arrangement
are available under this category.
6
· Percentage :- They multiply 100 with the cell value
& display it in the form of %.
· Fraction :- They display the cell values in the form of
a fraction.
· Scientific :- The cell values are displayed scientifically.
· Text :- Text format cells are treated as text even when the
number is in the cell, the cell is displayed exactly as
entered.
· Special :- They are useful for tracking list & database values.
· Custom :- Type the number format code, using one of
the existing codes as a starting point.
9
Types of conditional formatting:
On the Home tab, in the Style group, click the arrow next to
Conditional Formatting, and then click Highlight Cells Rules. Select the
command you want, such as Between, Equal To Text that Contains, or
A Date Occurring. Enter the values you want to use, and then select a
format.
Example- Passing marks are 20 marks .We are required to find who
scored less than 20.
10
Top/Bottom Rules are premade types of conditional formatting in Excel
used to change the appearance of cells in a range based on your
specified conditions.
Example ; suppose we are given marks of 6 students of a class. We are
required to find who scored above average.
Data Bars are horizontal bars added to each cell, much like a bar graph.
11
Color Scales change the color of each cell based on its value. Each color
scale uses a two- or three-color gradient. For example, in the Green-
Yellow-Red color scale, the highest values are green, the average
values are yellow, and the lowest values are red.
Icon Sets add a specific icon to each cell based on its value.
12
The Developer tab gives us the ability to work with features like
Macros, Add-ins, and also allows us to write our own VBA code that
will help us to automate anything we wish. This tab is hidden by
default.
Follow the below steps to unhide the Developer tab. This works on all
versions of Excel for Windows (Excel 2007,2010, 2013, 2016, 2019).
Note: This is a one-time process. Once you enable the Developer Tab, it
will always be shown in a custom ribbon for every Excel instance you
open, unless you go ahead and disable it explicitly.
Enabling The Developer
Tab #1) Click the File tab
Once you enable the Developer tab, it will be displayed on the ribbon
list.
15
But before sending you are asked to make some formatting like:
Insert the Title for every sheet that includes team name and week
number, mark it bold, and background yellow.
Draw a border
Bold the column headings.
Rename the sheet name as the team name.
Instead of doing this manually every week, you can just create a macro
and perform all these actions in just a click.
Recording macro is fairly easy. Navigate to the Developer tab, and hit
on Record Macro.
16
This will open up a window where you need to enter.
#1) Macro name: Name should not have spaces in between words. This
has to start with an alphabet or underscore.
#2) Shortcut key: This is useful when you are running a macro. If you
press the shortcut key, it will be executed. Make sure to give a key
which is not already taken, else macro will override that.
For example, if you mention Ctrl+S as the shortcut, then every time
you press Ctrl+S, your macro will be executed and thereby ignoring the
save file option. Hence it is recommended to add Shift, like
Ctrl+Shift+D
18
Selecting Store macro in as “Personal Macro workbook”: Now consider
selecting the Store macro in as “Personal Macro workbook” while
recording. You need to save the macro explicitly. If you just save the
Excel file and then try to close the file. Then you will receive a pop-up
dialog as shown below.
Note: If you don’t save this then the macro will be deleted.
Executing A Macro
Now that we are done with recording and saving the file, let’s try to
run it and achieve the desired results. We have gone ahead and
recorded a macro with all the steps required to achieve in the
attendance timesheet example and saved it as a This Workbook with
the shortcut key as Ctrl+Shift+B.
So every week when you receive a new Excel from the software tool,
you just have to open that Excel file and hit the shortcut key
(Ctrl+Shift+B) and all the changes will be incorporated as expected. The
resulting Excel is given below.
19
Q7. Is it possible to prevent someone from copying a cell from your
worksheet?
3) Select any of the check boxes in the Allow All Users of This
Worksheet To list box (such as Format Cells or Insert Columns) that
you still want to be functional when the worksheet protection is
operational.
20
The Select Locked Cells and Select Unlocked Cells check boxes are
selected by default.
5) Click OK.
Q8. What is Pivot table? Explain its uses with the help of example?
Ans. A pivot table is a data summarization tool that is used in the
context of data processing. Pivot tables are used to summarize, sort,
reorganize, group, count, total or average data stored in a database. It
21
allows its users to transform columns into rows and rows into columns.
It allows grouping by any data field.
Creation of pivot table
After your source data is prepared, you can create a pivot table. First,
see which pivot table layouts are suggested by Excel.
Select any cell in the source data
table. On the Ribbon, click the Insert
tab.
In the Tables group, click PivotTables.
Data cross checking can mean rechecking the data ( numbers for
example) to make sure they have been entered accurately. Validating
duty checking can be ensuring the base of the data was not skewed,
tampered with or faked. It enables you to validate data through cross-
verification from more than two sources.
23
Pivot chart: -
24
Q9. Explain the difference between substitute & replace function in
excel ?
25
26
27
Q10. What is the difference between COUNT, COUNTA, COUNTIF &
COUNTBLANK functions in excel ?
Ans. Difference between COUNT, COUNTA, COUNTIF, and
COUNTBLANK in MS-Excel :-
COUNTIF function: In case you want to count certain cells with criteria
then you need to go with COUNTIF function. You can select the
particular range/s for which you want the count.
28
Q11. What is IF function in excel. Also explain NESTED IF function?
Ans. IF is one of the Logical functions in Microsoft Excel, and there are 3
parts (arguments) to the IF function syntax:
logical_test : TEST something, such as the value in a cell.
Nested IF Function :-
29
If you need to do more than one logical test in a formula, you can
combine multiple IF functions in one formula. This is called a nested
formula, because the additional IF functions act as arguments, nested
within another IF function.
Q12. What is the use of LOOKUP function in excel. Show the use of
VLOOKUP & HLOOKUP function with the help of example ?
30
Ans. VLOOKUP stands for ‘Vertical Lookup’. It is a function that makes
Excel search for a certain value in a column (the so called ‘table array’),
in order to return a value from a different column in the same row.
This article will teach you how to use the VLOOKUP function.
In our example we have a list of fruits, the amount in stock and the
current price. We want to find the price of kiwi’s quickly in this table.
First, select a cell in which you want to publish the current price:
31
HLOOKUP function
Use HLOOKUP when your comparison values are located in a row
across the top of a table of data, and you want to look down a
specified
32
number of rows. Use VLOOKUP when your comparison values are
located in a column to the left of the data you want to find.
The H in HLOOKUP stands for "Horizontal."
HLOOKUP(lookup_value, table_array, row_index_num, [range_lookup])
The HLOOKUP function syntax has the following arguments:
▪ Lookup_value Required. The value to be found in the first row
of the table. Lookup_value can be a value, a reference, or a text
string.
▪ Table_array Required. A table of information in which data
is looked up. Use a reference to a range or a range name.
▪ The values in the first row of table_array can be
text, numbers, or logical values.
▪ If range_lookup is TRUE, the values in the first row of
table_array must be placed in ascending order: ...-2, -1, 0, 1,
2,... , A-Z, FALSE, TRUE; otherwise, HLOOKUP may not give
the correct value. If range_lookup is FALSE, table_array does
not need to be sorted.
▪ Uppercase and lowercase text are equivalent.
▪ Sort the values in ascending order, left to right. For
more information, see Sort data in a range or table.
▪ Row_index_num Required. The row number in table_array from
which the matching value will be returned. A row_index_num of
1 returns the first row value in table_array, a row_index_num of
2 returns the second row value in table_array, and so on. If
row_index_num is less than 1, HLOOKUP returns the #VALUE!
error value; if row_index_num is greater than the number of rows
on table_array, HLOOKUP returns the #REF! error value.
▪ Range_lookup Optional. A logical value that specifies whether
you want HLOOKUP to find an exact match or an approximate
match. If TRUE or omitted, an approximate match is returned. In
other words, if an exact match is not found, the next largest
value
33
that is less than lookup_value is returned. If FALSE, HLOOKUP will
find an exact match. If one is not found, the error value #N/A is
returned.
Ans. Cell Reference in excel is the way to represent the identity and the
location of any cell with the help of combining Column Name and Row
Number on a worksheet. For example, if we say cell B10, then it
expands as Column B and 10th Row. Similarly, we can define or declare
cell references to any position in the worksheet. We can also activate
R1C1 from Excel Options, another way for cell reference, where R1 is
Row1 and C1 is Column1.
37
We have the sales data for 4 sales managers across different months,
where sales have occurred multiple times in a month.
38
The result will be as:
You can use the Left function when you want to extract the leftmost
characters from a string. Syntax =left(text, num_char)
Similarly, you can also use the Right function to extract the rightmost
characters from a string.
42
2. Len ()
Len function in Excel helps you to know the length of a string that is
number of characters in a string. Syntax = LEN(text)
Note – Spaces are included while calculating length.
3. Mid ()
Mid function in Excel is used to extract the characters from the middle
of a string. Syntax = MID(text, start_char, num_chars)
4. Find ()
Find function in Excel is used when you want to know the position of
certain characters in a particular string. Syntax =FIND(find_text,
within_text,[start_num])
5. Proper ()
Proper function in Excel capitalizes each word in the string that is, it
converts the case into proper case. Syntax =PROPER(Text)
43
6. Rept ()
Rept function in Excel is used when you want a certain text to be
repeated certain number of times. Syntax =REPT(Text, number_times)
7. Trim()
Trim function in Excel removes the unnecessary spaces from a
particular string. Syntax =TRIM(Text )
8. Upper()
Upper function in Excel converts the text into Upper case from lower
case. Syntax =UPPER(Text )
9. Substitute ()
44
Substitute function in Excel helps to replace existing text with a new
text in a particular string. Syntax =SUBSTITUTE(text, old_text,
new_text, instance number)
10. Concatenate ()
Concatenate function in Excel helps to join the text of two or more
cells. Syntax =CONCATENATE(text1, text2….)
We use the count function when we need to count the number of cells
containing a number. Remember ONLY NUMBERS! Let’s see the
function:
COUNT(value1, [value2], …)
So, let’s try to find the answer to our first question – How many items
were on discount?
45
There are 11 products on discount.
2. Counta Function
While the count function only counts the numeric values, the COUNTA
function counts all the cells in a range that are not empty. The function
is useful for counting cells containing any type of information,
including error values and empty text.
COUNTA(value1, [value2], …)
We’ll answer the second question using the counta function since it is
able to count all the non-empty values – How many items/pieces of
equipment are sold by the store?
function!
4. Countifs Function
Countifs are one of the most used statistical functions in Excel. The
COUNTIFS function applies one or more conditions to the cells in the
given range and returns only those cells that fulfill all of the conditions.
COUNTIFS(criteria_range1, criteria1, [criteria_range2, criteria2]…)
Note: Every new range must have the same number of rows and
columns as the criteria_range1 argument. The ranges do not have to
be adjacent to each other.This function seems perfect to answer the
fourth question – Are there any products sold having cost more than
2000 along with a discount rate greater than 50%?
47
The
questions seemed complex but it was really easy to find the answer in
Excel. Only 1 product i.e., sneakers, cost more than 2000 and sold at a
discount rate greater than 20%.Wonderful, isn’t it? We have gone
through some basic statistical functions in MS Excel so far. Next, let’s
have a look at the intermediate statistical functions.
Intermediate Statistical Functions in Excel
We will discuss some of the intermediate statistical functions in MS
Excel here related to central tendency and dispersion. These functions
are very useful in our day to day life as an analyst.
5. Average Function
The most common function we usually use in our daily lives is the
average (or mean). The AVERAGE function simply returns the
arithmetic mean of all the cells in a given range:
AVERAGE(number1, [number2], …)
But there’s one simple drawback to using averages – they are prone to
outliers. Therefore, they can paint a very unrealistic picture in our
analysis. Let’s find out the average number of goods sold:dispersed
48
The average comes out to be ~ 365.2. We will be doing similar
calculations for cost as well.
6. Median Function
The problem of outliers can be solved by using another function for the
central tendency – median. The median function returns the middle
value of the given range of cells. The syntax is quite simple:
MEDIAN(number1, [number2], …)
Let’s find the median of the number of goods sold in our sports store
and see how close this is to our average value:
We see that the median comes out to be ~ 320 which is pretty close to
the average value. It means there is not much fluctuation in our data.
Let’s see if this is the case for the cost of goods:
The
median and the average value for the cost of each item vary a lot. For
example, the cost of a ball is 50 but the cost of a bat is 2000 – resulting
in high dispersion.
49
7. Mode Function
For numerical values, mean and median usually, suffice but what about
categorical values? Here, mode comes into the picture. Mode returns
the most frequent and repeated value in the given range of values:
MODE.SNGL(number1,[number2],…)
Note: MODE.SNGL returns only a single value whereas MODE.MULT
returns an array of most commonly occurring values.
Well, this is a simple one. Let’s find the most frequent discount value
given by the sports store:
This
discount value is 10%.
9. Quartiles Functions
This is yet another function with abundant applications in the industry.
It helps us divide the population into groups. The QUARTILES.INC
returns the quartile of a dataset, based on percentile values from 0 to
1, inclusive.
For example, you can use this function to find out the top 25% of your
customer base.
QUARTILE.INC(array, quart)
1. The IF function :-
The IF function is the key logical function used for decision making. It
takes the format:
=IF(condition, true, false)
For example, you could use the following formula:
52
=IF(B2 > 2000, “High”, “Low”) where,
B2 > 2000 is the condition being
tested.
“High” is the text to display if B2 is greater than 2000 (the result of the
test is yes or TRUE)
“Low” is the text to display if B2 is less than or equal to 2000 (the result
of the test is no or FALSE).
53
2. The AND function :-
The AND function is used to compare more than one condition. It
returns TRUE only if all of the conditions are met, and takes the
format:
=AND(condition1, condition2,…)
For example, you could use the following formula:
=AND(B2 > 400, C2 < 300) where,
B2 > 400 is the first condition being tested
C2 < 300 is the second condition being tested
This will only return the result TRUE if the value in cell B2 is greater
than 400 and the value in cell C2 is less than 300. In all other situations,
the result will be FALSE.
54
3) The OR function :-
55
4) Nested IF :-
5) NOT Function:-
Returns the reversed logical value of its argument. I.e. If the argument
is FALSE, then TRUE is returned and vice versa.
57
Q19. Explain MATCH & INDEX function with
syntax? Ans. INDEX function :-
The INDEX function in Excel is fantastically flexible and powerful, and
you'll find it in a huge number of Excel formulas, especially advanced
formulas. But what does INDEX actually do? In a nutshell, INDEX
retrieves the value at a given location in a range. For example, let's say
you have a table of planets in our solar system (see below), and you
want to get the name of the 4th planet, Mars, with a formula.
58
MATCH function:-
The MATCH function in Excel searches for a specified value in a range of
cells, and returns the relative position of that value.
The syntax for the MATCH function is as follows:
=MATCH(lookup_value, lookup_array, [match_type])
Lookup_value (required) - the value you want to find. It can be a
numeric, text or logical value as well as a cell reference.
Lookup_array (required) - the range of cells to search in.
Match_type (optional) - defines the match type. It can be one of these
values: 1, 0, -1. The match_type argument set to 0 returns only the
exact match, while the other two types allow for approximate match.
· 1 or omitted (default) - find the largest value in the lookup array
that is less than or equal to the lookup value. Requires sorting the
lookup array in ascending order, from smallest to largest or from
A to Z.
· 0 - find the first value in the array that is exactly equal to
the lookup value. No sorting is required.
59
· -1 - find the smallest value in the array that is greater than or
equal to the lookup value. The lookup array should be sorted
in descending order, from largest to smallest or from Z to A.
To better understand the MATCH function, let's make a simple formula
based on this data: students names in column A and their exam scores
in column B, sorted from largest to smallest. To find out where a
specific student (say, Laura) stands among others, use this simple
formula:
=MATCH("Laura", A2:A8, 0)
Q20. Explain WHAT IF analysis. Show the use of goal seek, data table &
scenario manager?
Ans. What-If Analysis in Excel allows you to try out different values
(scenarios) for formulas. The following example helps you master
what- if analysis quickly and easily.
Assume you own a book store and have 100 books in storage. You sell
a certain % for the highest price of $50 and a certain % for the lower
price of $20.
60
If you sell 60% for the highest price, cell D10 calculates a total profit of
60 * $50 + 40 * $20 = $3800.
61
The Scenario Manager dialog box appears.
1. Add a scenario by clicking on Add.
Scenario Summary
To easily compare the results of these scenarios, execute the following
steps.
1. Click the Summary button in the Scenario Manager.
2. Next, select cell D10 (total profit) for the result cell and click on OK.
63
Result:
Conclusion: if you sell 70% for the highest price, you obtain a total
profit of $4100, if you sell 80% for the highest price, you obtain a total
profit of $4400, etc. That's how easy what-if analysis in Excel can be.
Goal Seek
What if you want to know how many books you need to sell for the
highest price, to obtain a total profit of exactly $4700? You can
use Excel's Goal Seek feature to find the answer.
1. On the Data tab, in the Forecast group, click What-If Analysis.
64
2. Click Goal Seek.
Result. You need to sell 90% of the books for the highest price to
obtain a total profit of exactly $4700.
65
Q21. State financial model for one period & forecast it for next 4 years?
Ans.
66
Q22. How to build a template in excel?
67
4. Enter a file name.
5. Select Excel Template (*.xltx) from the drop-down list.
68
Excel automatically activates the Templates folder. Notice the location
of the Templates folder on your computer. It's usually located here:
C:\Users\<username>\Documents\Custom Office Templates
6. Click Save.
69
Excel creates the workbook WeddingBudget1.xlsx based on
this template.
Note: to edit a template, on the File tab, click Open and then
click Browse, to open the template. Edit the file and save the file
to its original location.
Q23. What are TREND & FORECAST functions in excel?
Ans. Forecast
A forecast predicts something for the future. For example, the
expectations of the future numbers in terms of company growth can
be called a forecast. The forecast function, in short, is used to calculate
the straight lines that are based on known X and Y values. The values of
Y can be calculated for the values of X inside or outside the range of
the X values.
70
Trend
When you add a trendline to an Excel chart, Excel can display the
equation in a chart (see below). You can use this equation to calculate
future sales. The FORECAST and TREND function give the exact same
result.
Explanation: Excel uses the method of least squares to find a line that
best fits the points. The R-squared value equals 0.9295, which is a good
fit. The closer to 1, the better the line fits the data.
1. Use the equation to calculate future sales.
71
2. Use the FORECAST function to calculate future sales.
72
Note: first, select the range E12:E14. Next, type
=TREND(B2:B11,A2:A11,A12:A14). Finish by pressing CTRL + SHIFT +
ENTER. The formula bar indicates that this is an array formula b
enclosing it in curly braces {}. To delete this array formula, select the
range E12:E14 and press Delete.
73
EXAMPLES USING PMT
Calculating annual and monthly payments
Examples A and B: Your client desires a balance of $1 million in a
retirement account by the end of 20 years, and you project an annual
return of 6% on investments. To determine how your client can reach
this goal, the formula =PMT(0.06,20,0,-1000000,0) can be applied. As
shown in cell B13 of the screenshot "Using the PMT Function," the
client's required annual contribution at the end of each year would be
$27,185. Alternatively, if the client already has $100,000 in existing
retirement savings, cell B26 of the screenshot reveals the required
74
annual deposit would be only $18,466, calculated by applying the
formula =PMT(0.06,20,100000,-1000000,0).
Reviewing such calculations can be very eye-opening with younger
clients who are just starting to save for retirement. This analysis can
show them the value of starting their retirement savings early to reach
their goals.
75
EXAMPLES USING NPER
Calculating the number of months or years
Examples A and B: A client wants to know how long it would take for
her to achieve a retirement balance of $1 million if she plans on
contributing $1,250 per month and will earn a 10% annual return (or
0.8333% monthly return). The formula =NPER(0.008333,1250,0,-
76
1000000,1) is applied in cell B13 of the screenshot "Using the NPER
Function" to calculate that it would take over 244 months, or about
20 years and five months, to reach her retirement goal. If the client
already had $100,000 in existing retirement savings, her goal would
be reached in about 183 months, or 15 years and four months, as
shown in cell B28 and calculated by applying the
formula =NPER(0.008333,1250,100000,-1000000,1).
77
Q25. Show some questions based on capital budgeting?
78
Q26. Show some questions based on ratio analysis?
Ans.
79