PC Review


Reply
Thread Tools Rate Thread

Compounding Interest

 
 
nerak
Guest
Posts: n/a
 
      27th Jan 2010
I am trying to find the best way to formulate for compounding interest with
different start dates and different finish dates but the interest percentage
the same. When I only had a few months I just put a formula in the query
which worked OK but when I went beyond 10 months I got the message 'too
complicated' when I ran the query.

I would like to know if a query is the best place to put this and can I use
macros for this or do I need VBA? I have looked at formula of finance but
that only covers stable totals and interest. Can anyone help please.

Regards nerak
 
Reply With Quote
 
 
 
 
Daryl S
Guest
Posts: n/a
 
      27th Jan 2010
Nerak -

I would use a function for this (VBA code) in a general module. That way
you can call it from any query or form or report you want.

You would need to pass in the start date, end date, principal, interest
rate, and compounding_Frequency, and return the interest earned. If the
compounding frequency is fixed (e.g. you ALWAYS compound monthly or ALWAYS
compound daily, then you don't need to pass it in, just set it in the
function).

Depending on your need for accuracy and your business rules, you may need to
decide if compounding date is important. In other words, if you compound
monthly, do you always credit the earned interest on the last day of the
month, or do you credit it on the month anniversary of the start date? That
may not be an issue for most exercises.

Here is one to get you started. It assumes compounding monthly (12 times a
year). Open a new module and copy/paste this in (you may need to correct for
wrapping in the posting):


Public Function GetCmpdInterest(StartDate As Date, EndDate As Date, PrincAmt
As Double, IntRate As Double) As Double
'This will calculate compound interest assuming monthly compounding.
'This is a straight mathematical calculation, not taking into account any
fixed accrual dates.

Dim NumPeriods As Double 'Some some accrual methods would want this to be
integer
Dim CompoundInterest As Double

NumPeriods = (EndDate - StartDate) * 12 / 365 'the 12 indicates compounding
12 times a year
CompoundInterest = PrincAmt * (1 + IntRate / 12) ^ NumPeriods - PrincAmt

GetCmpdInterest = CompoundInterest

End Function


Then in your query, add a field like this:

CmpdDiv:
GetCmpdInterest([StartDate],[EndDate],[StartingPrincipal],[AnnualInterestRate])

Note the AnnualInterestRate should be entered like 0.06 for a 6% interest
rate.

Try it out and adjust as needed.
--
Daryl S


"nerak" wrote:

> I am trying to find the best way to formulate for compounding interest with
> different start dates and different finish dates but the interest percentage
> the same. When I only had a few months I just put a formula in the query
> which worked OK but when I went beyond 10 months I got the message 'too
> complicated' when I ran the query.
>
> I would like to know if a query is the best place to put this and can I use
> macros for this or do I need VBA? I have looked at formula of finance but
> that only covers stable totals and interest. Can anyone help please.
>
> Regards nerak

 
Reply With Quote
 
nerak
Guest
Posts: n/a
 
      28th Jan 2010
Thank you so much Daryl I truly appreciate your time and clarity in answering
this.

Have a fantastic day!

"Daryl S" wrote:

> Nerak -
>
> I would use a function for this (VBA code) in a general module. That way
> you can call it from any query or form or report you want.
>
> You would need to pass in the start date, end date, principal, interest
> rate, and compounding_Frequency, and return the interest earned. If the
> compounding frequency is fixed (e.g. you ALWAYS compound monthly or ALWAYS
> compound daily, then you don't need to pass it in, just set it in the
> function).
>
> Depending on your need for accuracy and your business rules, you may need to
> decide if compounding date is important. In other words, if you compound
> monthly, do you always credit the earned interest on the last day of the
> month, or do you credit it on the month anniversary of the start date? That
> may not be an issue for most exercises.
>
> Here is one to get you started. It assumes compounding monthly (12 times a
> year). Open a new module and copy/paste this in (you may need to correct for
> wrapping in the posting):
>
>
> Public Function GetCmpdInterest(StartDate As Date, EndDate As Date, PrincAmt
> As Double, IntRate As Double) As Double
> 'This will calculate compound interest assuming monthly compounding.
> 'This is a straight mathematical calculation, not taking into account any
> fixed accrual dates.
>
> Dim NumPeriods As Double 'Some some accrual methods would want this to be
> integer
> Dim CompoundInterest As Double
>
> NumPeriods = (EndDate - StartDate) * 12 / 365 'the 12 indicates compounding
> 12 times a year
> CompoundInterest = PrincAmt * (1 + IntRate / 12) ^ NumPeriods - PrincAmt
>
> GetCmpdInterest = CompoundInterest
>
> End Function
>
>
> Then in your query, add a field like this:
>
> CmpdDiv:
> GetCmpdInterest([StartDate],[EndDate],[StartingPrincipal],[AnnualInterestRate])
>
> Note the AnnualInterestRate should be entered like 0.06 for a 6% interest
> rate.
>
> Try it out and adjust as needed.
> --
> Daryl S
>
>
> "nerak" wrote:
>
> > I am trying to find the best way to formulate for compounding interest with
> > different start dates and different finish dates but the interest percentage
> > the same. When I only had a few months I just put a formula in the query
> > which worked OK but when I went beyond 10 months I got the message 'too
> > complicated' when I ran the query.
> >
> > I would like to know if a query is the best place to put this and can I use
> > macros for this or do I need VBA? I have looked at formula of finance but
> > that only covers stable totals and interest. Can anyone help please.
> >
> > Regards nerak

 
Reply With Quote
 
New Member
Join Date: Jan 2012
Posts: 1
 
      11th Jan 2012
Hi,
I am an IT trainee trying to create a property management system on MS access 2007. The rent escalates annually at a rate of 10% thus formula for working out new rent is similar to compound interest. I am trying to build a code or expression that would automate the rent escalation..., please help me out.
Thanks, Peter.
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Compounding Interest Rich Stanek Microsoft Excel Misc 1 13th Dec 2007 09:49 PM
Which formula to use for compounding interest for specific # of da =?Utf-8?B?Uk9M?= Microsoft Excel Worksheet Functions 1 30th May 2006 08:14 PM
Compounding Interest Formula Florida Flamingo Microsoft Excel Misc 1 1st Jan 2006 10:49 PM
Compounding Interest =?Utf-8?B?SmFzb24=?= Microsoft Excel Misc 6 29th Mar 2005 02:51 PM
Formula for compounding Interest John Hornblow Microsoft Excel Worksheet Functions 2 23rd Aug 2003 09:40 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:28 PM.