Jim Seymour wrote:

I have researched repeatedly and cannot find an answer to the following. I
need to do something like the following (There is probably an easier
way).

end_date - start_date = diff / start_date = return for period

The table contains 401k investment values. Ideas, pointers, etc.? I am using
mysql v5.0.12 on Debian Linux.

TIA,

Jim

Depending on how fancy you want to get, you would calculate either an IRR (Internal Rate of Return) that basically says, what interest rate would I need to get on the funds to end up with the same results I actually achived. Note that calculating an interest rate is going to require an iterative approximation.



http://www.investopedia.com/offsite.asp?URL=http://invest-faq.com/articles/analy-int-rate-return.html includes a description of the general concepts and a pointer to some programs, including (401-calc) that calculate IRR.

http://fox.wikis.com/wc.dll?Wiki~InternalRateOfReturn has some code that uses Newton-Raphson approximation to calculate IRR.

Googling for "Internal Rate of Return" can find you a lot more links.

There are also more sophisticated techniques like FMRR that are used when you have minimum investment amounts and a lower rate of return on short term investments of money waiting to accumulate the larger somes needed.


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to