Академический Документы
Профессиональный Документы
Культура Документы
Training
Module 1.1
- Advance
Function
cont.
R e g i n a r d C . F a j a n o y, M I T
BS Computer Science | Programming NCIV | Visual Graphics NCIII
Blitz
I . T. S o l u t i o n
DateDif
DateDif
Step 1: Fill in "d" for the third argument to get the number of days
between two dates.
DateDif
Step 2: Fill in "m" for the third argument to get the number of months
between two dates.
Step 3: Fill in "y" for the third argument to get the number of years
between two dates.
DateDif
Step 4: Fill in "yd" for the third argument to ignore years and get the
number of days between two dates.
Step 5: Fill in "md" for the third argument to ignore months and get the
number of days between two dates.
DateDif
Step 6: Fill in ym" for the third argument to ignore years and get the
number of months between two dates.
DateDif
Weekdays
Weekdays
Weekday Function
1. The WEEKDAY function in Excel returns a number from 1 (Sunday) to 7
(Saturday) representing the day of the week of a date. Apparently,
4/12/2015 falls on a Sunday.
2. You can also use the TEXT function to display the day of the
week.
Weekdays
3. Create acustom date format(dddd) to display the day of the week.
Networkdays Function
1. The NETWORKDAYS function returns the number of weekdays
(weekends excluded) between two dates.
Networkdays
1. The NETWORKDAYS function returns the number of weekdays
(weekends excluded) between two dates.
Networkdays
2. If you supply a list of holidays, the NETWORKDAYS function returns the
number of workdays (weekends and holidays excluded) between two
dates.
Networkdays
3. Dates are stored as numbers in Excel and count the number of days
since January 0, 1900. Instead of supplying a list, supply an array
constant of the numbers that represent these dates. To achieve this,
select E1:E2 in the formula and press F9.
Workday
The WORKDAY function is (almost) the opposite of the NETWORKDAYS
function. It returns the date before or after a specified number of
weekdays (weekends excluded).
EDATE
Get the same date in future or past months.
3. The most difficult part in order to get the number of days until your
birthday is to find your next birthday. The formula below does the trick.
Explanation: The DATE function accepts three arguments: year, month and
day. We used theDATEDIFfunction to find the number of complete years
("y") between Date of Birth and Today. DATEDIF(A2,B2,"y") equals 27. If 27
complete years have passed since your date of birth (in other words, you
have already celebrated your 27th birthday), your next birthday will be 27 + 1
= 28 years after your date of birth.
Time Sheet
This example teaches you how to create a simpletimesheetcalculator
inExcel. Cells that contain formulas are colored light green.
1. To automatically calculate the next 4 days and dates when you enter a
start date, use the formulas below.
Time Sheet
Time Sheet
3. Right click, click Format Cells, and select the right Time format. Use the
circled format for cell K12, K13, K14.
Time Sheet
4. To automatically calculate the hours worked each day, the total hours and
the overtime hours, use the formulas below.
Time Sheet
Last Day of the Month
To get the date of thelast day of the monthinExcel, use the EOMONTH (End
of Month) function.
1. For example, get the date of the last day of the current month.
Note: the EOMONTH function
returns the serial number of
the date.
2. For example, get the date of the last day of the next month.
Time Sheet
3. For example, get the date of the last day of the current month - 8
months = 4 - 8 = -4 = August (-4+12=8), 2014!
Choose
theCHOOSEfunction returns a value from a list of values, based on a
position number. For example, =CHOOSE(3,"Car","Train","Boat","Plane")
returns Boat.
Quarter
An easy formula that returns thequarterfor a given date. There's no built-in
function inExcelthat can do this.
1. Enter the formula shown below.
Quarter
ay of the Year
An easy formula that returns theday of the yearfor a given date. There's no
built-in function inExcelthat can do this.
1. Enter the formula shown below.
ext Function
Excelhas many
functions to offer
when it comes to
manipulatingtext
strings.
ext Function
Join Strings
To join strings, use the & operator.
ext Function
Left
To extract the leftmost characters from a string, use the LEFT function.
Right
To extract the rightmost characters from a string, use the RIGHT function.
ext Function
Mid
To extract a substring, starting in the middle of a string, use the MID
function.
Note: started at
position 5 (p) with
length 3.
Len
To get the length of a string, use the LEN function.
ext Function
Find
To find the position of a substring in a string, use the FIND function.
Note: string ol" found
at position 3.
Substitute
To replace existing text with new text in a string, use the SUBSTITUTE
function.
ext Function
Separate Strings
This example teaches you how toseparate stringsinExcel.
The problem we are dealing with is that we need to tell Excel where we
want to separate the string. In case of Tamad, Juan the comma is at
position 6 while in case of Don, Pedro the comma is at position 4 .
ext Function
ext Function
2. To get the last name, use the following formula.
ext Function
Number of Instances
This example describes how tocount the number of instances of text (or a
number) in a cell.
1. Use the LEN function to get the length of the string (13 characters,
including spaces).
2. The SUBSTITUTE function replaces existing text with new text in a string.
LEN(SUBSTITUTE(A1,B1,"")) equals 11 (the length of the string without the
word mango). If we subtract this number from 36, we get the length of the
mango instances (36-11=20).
ext Function
3. Dividing this number by the length of the word mango (5), gives us the
dog instances (20/5=4).
ext Function
Number of Words
This example describes how to count thenumber of wordsin acell.
1a. The TRIM function returns a string with extra spaces, starting spaces and
ending spaces removed.
1b. To get the length of the string with normal spaces, we combine the LEN
and TRIM function.
ext Function
2a. The SUBSTITUTE function replaces existing text with new text in a text
string. We use the SUBSTITUTE function to get the string without spaces.
2b. To get the length of the string without spaces, we combine the LEN
and SUBSTITUTE function.
3. Now comes the simple trick. To get the number of words, we subtract
the length of the string without spaces (10) from the length of the string
with normal spaces (12) and add 1.
ext Function
Text to Columns
To separate the contents of oneExcel cellintoseparate columns, you can
use the 'Convert Text to Columns Wizard'. For example, when you want to
separate a list of full names into last and first names.
1. Select the range with full names.
ext Function
ext Function
4. Clear all the check boxes under Delimiters except for the Comma
and Space check box.
5. Click Finish.
ext Function
Result:
ext Function
Lower/Upper Case
This example teaches you how to convert a text string to lower, upper or
proper case inExcel.
1. Use theLOWER functionto convert all letters in a text string tolowercase.
ext Function
Removed Unwanted Characters
The TRIM function returns a string with extraspaces, starting spaces and
ending spaces removed. The CLEAN functionremoves nonprintable
charactersfrom a string.
1. For example, cell A1 below contains the string "ExcelEasy"
Note: the
TRIM function
returns the
string "Excel
Easy".
2. For example, cell A1 below contains a nonprintable
character.
Note: the CLEAN
function removes this
nonprintable
character. Text
imported from other
applications may
contain nonprintable
characters.
ext Function
Compare Text
This example shows two ways tocompare textinExcel. One is case-sensitive
and one is case-insensitive.
1. Use the EXACT function (case-sensitive).
ext Function
Find vs Search
TheFIND functionand theSEARCH functionare very similar to each other.
This example shows the difference.
1. To find the position of a substring in a string, use the FIND function. FIND
is case-sensitive.
ext Function
3. The SEARCH function is more versatile. You can use wildcard characters
when you use this function.
ext Function
4. One other interesting point to mention about the FIND and the SEARCH
function is that they have a 3rd optional argument. You can use this
argument to indicate the position, counting from the left, at which you want
to start searching.
Note: string e" found
at position 11.
ext Function
Substitute vs Replace
This example shows the difference between theSUBSTITUTE functionand
theREPLACE function.
1a. If you know the text to be replaced, use the SUBSTITUTE function.
1b. The SUBSTITUTE function has a 4th optional argument. You can use
this argument to indicate which occurrence you want to substitute.
ext Function
2. If you know the position of the text to be replaced, use the REPLACE
function.
nancial Functions
Pmt
Get the periodic payment for a loan
Parameter list:
Syntax
=PMT (rate, pmt, pv, [fv], [type]
Pmt
The PMT function can be used to figure out the future payments for a
loan, assuming constant payments and a constant interest rate. For
example, if you are borrowing Php10,000 on a 24 month loan with an
annual interest rate of 8 percent, PMT can tell you what your monthly
payments be and how much principal and interest you are paying each
month.
Notes:
1. The payment returned by PMT includes principal and interest but will
not include any taxes, reserve payments, or fees.
2. Be sure you are consistent with the units you supply for rate and
nper. If you make monthly payments on a three-year loan at an
annual interest rate of 8 percent, use 8%/12 for rate and 3*12 for
nper. For annual payments on the same loan, use 8 percent for rate
and 3 for nper.
Pmt
The PMT function can be used to figure out the future payments for a
loan, assuming constant payments and a constant interest rate. For
example, if you are borrowing Php10,000 on a 24 month loan with an
annual interest rate of 8 percent, PMT can tell you what your monthly
payments be and how much principal and interest you are paying each
month.
Notes:
1. The payment returned by PMT includes principal and interest but will not
include any taxes, reserve payments, or fees.
2. Be sure you are consistent with the units you supply for rate and nper. If
you make monthly payments on a three-year loan at an annual interest
rate of 8 percent, use 8%/12 for rate and 3*12 for nper. For annual
payments on the same loan, use 8 percent for rate and 3 for nper.
Pmt
The PMT function can be used to figure out the future payments for a
loan, assuming constant payments and a constant interest rate. For
example, if you are borrowing Php10,000 on a 24 month loan with an
annual interest rate of 8 percent, PMT can tell you what your monthly
payments be and how much principal and interest you are paying each
month.
Note: The last two arguments are optional. For loans the Fv can
be omitted (the future value of a loan equals 0, however, it's
included here for clarification). If Type is omitted, it is assumed
that payments are due at the end of the period.
Pmt
The PMT function can be used to figure out the future payments for a
loan, assuming constant payments and a constant interest rate. For
example, if you are borrowing Php10,000 on a 24 month loan with an
annual interest rate of 8 percent, PMT can tell you what your monthly
payments be and how much principal and interest you are paying each
month.
Rate
Get the interest rate per period of an annuity
Syntax
=RATE (nper, pmt, pv, [fv], [type], [guess]
Parameter list:
Rate
If Rate is the only
unknown variable, we
can use the RATE
function to calculate
the interest rate.
Notes:
1. You must be consistent with units forguessandnper.
2. If you make monthly payments on a five-year loan at 10 percent
annual interest, use 10%/12 forguessand 5*12 fornper.
3. If you make annual payments on the same loan, use 10% for guess and
5 fornper.
Nper
Get the number of periods for an investment
Syntax
Parameter list:
Nper
If we make monthly
payments of $1,074.65
on a 20-year loan, with
an annual interest rate
of 6%, it takes 240
months to pay off this
loan.
You can use the NPER function to get the number of periods for an
investment when payments and the interest rate are constant.
Notes:
1. PMT normally includes principal and interest but not taxes, reserve
payments, or fees.
2. Be sure you supplyrateconsistent with periods. For example, if an
annual interest rate is 12 percent, use 12%/12 forrateto get NPER to
return periods in months.
Pv
Get the present value of an investmentSyntax
Parameter list:
Pv
If we make monthly
payments of
Php1,074.65 on a 20year loan, with an
annual interest rate of
6%, how much can we
borrow?
The PV function returns the value in today's dollars of a series of future
payments, assuming periodic, constant payments and a constant interest
rate.
Notes
1. A stream of cash flows that includes the same amount of cash outflow
(or inflow) each period is called an annuity. For example, a car loan or a
mortgage is an annuity. When each period's interest rate is the same, an
annuity can be valued using the PV function.
2. In annuity functions, cash you pay out, such as a deposit to savings, is
represented by a negative number; cash you receive, such as a dividend
check, is represented by a positive number. For example, a Php2,500
Fv
Get the future value of an investment Syntax
Parameter list:
Fv
If we make monthly
payments of $1,074.65
on a 20-year loan, with
an annual interest rate
of 6%, do we pay off
this loan?
The future value (FV) function calculates the future value of an investment
assuming periodic, constant payments with a constant interest rate.
Notes:
1. Units forrateandnpermust be consistent. For example, if you make
monthly payments on a four-year loan at 12 percent annual interest, use
12%/12 (annual rate/12 = monthly interest rate) forrateand 4*12 (48
payments total) fornper. If you make annual payments on the same loan,
use 12% (annual interest) forrateand 4 (4 payments total) fornper.
2. Ifpmtis for cash out (i.e deposits to saving, etc), payment value must
be negative; for cash received (income, dividends), payment value must
be positive.
Fv
Conclusion:
the longer the duration of the loan, the more interest you pay.
vestment or Annuity
This example teaches you how to calculate thefuture valueof
aninvestmentor thepresent valueof anannuity.
Tip:
Investment
Assume that at the end of every year, you deposit Php100 into a savings
account. At an annual interest rate of 8%, how much will your
investment be worth after 10 years?
vestment or Annuity
This example teaches you how to calculate thefuture valueof
aninvestmentor thepresent valueof anannuity.
Tip:
Note:
vestment or Annuity
Annuity
Assume you want to purchase an annuity that will pay Php600 a month,
for the next 20 years. At an annual interest rate of 6%, how much does
the annuity cost?
ompound Interest
What'scompound interestand what's the formula for
compound interest inExcel?
Assume you put Php100 into a bank. How much will your
investment be worth after one year at an annual interest rate of
8%?
ompound Interest
Now this interest (Php8) will also earn interest (compound
interest) next year. How much will your investment be worth
after two years at an annual interest rate of 8%?
ompound Interest
How much will your investment be worth after 5 years? Simply
drag the formula down to cell B8.
ompound Interest
All we did was multiplying Php100 by 1.08, 5 times. So we can
also directly calculate the value of the investment after 5 years.
Note: there is no
special function for
compound interest in
Excel.
vity Time!
Assume you put Php10,000 into a bank. How much will your
investment be worth after 10 years at an annual interest rate of
5% compounded monthly?
Formula:
ctivity Time!
Solution:
vity Time!
How
About?
oan Amortization
Use thePMTfunction to calculate the monthly payment on a loan with
an annual interest rate of 5%, a 2-year duration and a present value
(amount borrowed) of Php 20,000
oan Amortization
Use the PPMT function to calculate the principal part of the payment.
The second argument specifies the payment number.
Note:
oan Amortization
Use the IPMT function to calculate the interest part of the payment. The
second argument specifies the payment number.
Note:
oan Amortization
Update the balance
Change the
formula >
oan Amortization
eciation -
See Example
Depreciation
SLN
The SLN (Straight Line) function is easy. Each year thedepreciation
valueis the same.
The SLN function performs the following calculation.
Deprecation Value = (10,000 - 1,000) / 10 = 900.00.
If we subtract this value 10 times, the asset
depreciates from 10,000 to 1000 in 10 years (see
first picture, bottom half).
Depreciation
SYD -
The SYD (Sum of Years' Digits) function is also easy. As you can
see below, this function also requires the period number.
Depreciation
DB -
Depreciation
Note:
DB function
- has a fifth optional argument. You can use this argument to
indicate the number of months to go in the first year (If omitted, it is
assumed to be 12). For example, set this argument to 9 if you
purchase your asset at the beginning of the second quarter in year 1
(9 months to go in the first year). Excel uses a slightly different
formula to calculate the deprecation value for the first and last period
(the last period represents an 11th year with only 3 months).
Depreciation
DDB -
Depreciation
Note: the DDB function has a fifth optional argument. You can use this
Depreciation
VDB -The VDB (Variable Declaring Balance) function uses the DDB
(Double Declining Balance) method by default. The 4th argument indicates
the starting period, the 5th argument indicates the ending period.
Depreciation
The VDB function performs the same calculations as the DDB function.
However, it switches to Straight Line calculation (yellow values) to make
sure you reach the salvage value (see first picture, bottom half). It only
switches to Straight Line calculation when Depreciation Value, Straight
Line is higher than Depreciation Value, DDB. In period 8, Depreciation
Value, DDB = 419.43. We still have 2097.15 - 1000 (see first picture,
bottom half) to depreciate. If we use the Straight Line method this results
in 3 remaining depreciation values of 1097.15 / 3 = 365.72.
Depreciation