NetPresentValue ( listOfPayments ; interestRate )
Rate this function: Average rating: 4.0 (44 votes) Discuss this Custom Function
Michael Horak, *COMMENT Visual Realisation
http://comment.cjb.net/
Same as Filemaker's native NPV() function  but payments do not need to be listed in a repeating field.
Sample Input:
NetPresentValue ( List ( 2000; 600; 300; 500; 700; 400 ) ; 0.5 ) 

Sample Output:

Description:
Returns the net present value (NPV) of a series of unequal future payments (negative values) and income (positive values) occuring at regular intervals, assuming a fixed interestRate per interval.
Same as Filemaker's native NPV() function  but payments do not need to be listed in a repeating field.
Use this function to calculate NPV. For example, if you invest a sum of money and get paid back unequal amounts over a period of several years, you can use the NetPresentValue function to calculate the net present value of your investment.
Examples
NetPresentValue ( List ( 2000; 600; 300; 500; 700; 400 ) ; 0.5 ) returns 156.9127744508813684
NetPresentValue ( List ( Payments::Amount ) ; 0.1 ) returns 16758.3560487050685808 when the related records in the Payments table contain the amounts of 5000 (the initial investment), 10,000, 0, 10,000, and 10,000.
NOTE:
The data for these examples comes from Filemaker's help on the NPV() function  in order to demonstrate that the custom function returns the same results as the native one.
However, in the original text the negative amounts 2000 and 5000 are called "the initial payment" or "the initial investment". Unfortunately, this is quite incorrect: the first amount in the series is presumed to be paid AT THE END of the first period, not at the beginning of the entire transaction, as one would expect.
To calculate the correct NPV in a situation where the series of payments is preceded by an initial income (or vice versa), calculate the NPV of future payments only and subtract the initial income from the result, e.g.:
NetPresentValue ( List ( 600; 300; 500; 700; 400 ) ; 0.5 )  2000
returns 164.7584131734254368.
Note: these functions are not guaranteed
or supported by BrianDunning.com. Please contact the individual
developer with any questions or problems.
This is my Custom Function and I want to
edit it
Discuss:There are no comments yet. Be the first to post a comment about this Custom Function! Please try to keep it brief & to the point. Anyone can post:

Newest Custom Functions:
1. 
decFromHex ( hexValue ) 

(Mon, Oct 16, 12:34pm) 
2. 
MonthYearList ( startmonth ; startyear ; numbermonth ; short ) 

(Mon, Oct 16, 3:38am) 
3. 
ErrorDescription ( errorNumber ) 

(Wed, Sep 27, 2:51am) 
4. 
decodeEntities (text) 

(Wed, Sep 27, 1:22am) 
5. 
HexidecimalToNumber ( HexidecimalValue ; counter ) 

(Mon, Sep 25, 12:39pm) 
6. 
FixedFieldConverter ( Fieldname ; f1 ; f2 ; f3 ; f4 ; f5 ; f6 ; f7 ; f8 ; f9 ; f10 ; f11 ; f12 ; f13 ; f14 ; f15 ; f16 ; f17 ; f18 ; f1 

(Fri, Sep 15, 12:34pm) 
7. 
ShannonEntropy ( text ) 

(Thu, Sep 07, 5:59am) 
8. 
LetterCount ( text ; summary ) 

(Thu, Sep 07, 5:53am) 

