Professional Documents
Culture Documents
2008
Charles Flock and Joe Stampf found
WestClinTech and introduce
2010 - 2011
XLeratorDB with over 350 Finance, More than 250 new functions added to
Statistics, Math and Engineering XLeratorDB.
functions.
2008
First commercial sale of
XLeratorDB.
2012 - Present
XLeratorDB releases new Financial-
Options, CAPM and Windowing
functions. Client list grows to over 400
and function list grows to more than
650.
No. of
Function Excel 2010 XLeratorDB Difference
Records
XIRR – Internal Rate of Return (irregular cash flows) 2,700,080 8.32 min. 1.33 min. -84%
ACCRINTM – Accrued Interest at Maturity 1,000,000 3.5 min. 1.099 min. -68.5%
Desktop
Single Server
Server Cluster
XLeratorDB in
the Cloud
Use DURATION to calculate the annual duration of a security with regular, periodic interest payments.
Syntax
SELECT [westclintech].[wct].[DURATION] (
<@Settlement, datetime,>
,<@Maturity, datetime,>
,<@Rate, float,>
,<@Yld, float,>
,<@Frequency, float,>
,<@Basis, nvarchar(4000),>)
Arguments
@Settlement
the settlement date of the security. @Settlement is an expression that returns a datetime or smalldatetime value, or a character string in date format.
@Maturity
the maturity date of the security. @Maturity is an expression that returns a datetime or smalldatetime value, or a character string in date format.
@Rate
the security’s annual coupon rate. @Rate is an expression of type float or of a type that can be implicitly converted to float.
@Yld
the security’s annual yield. @Yld is an expression of type float or of a type that can be implicitly converted to float.
@Frequency
the number of coupon payments per year. For annual payments, @Frequency = 1; for semi-annual, @Frequency = 2; for quarterly, @Frequency = 4; for monthly, @Frequency = 12. @Frequency is
an expression of type float or of a type that can be implicitly converted to float.
@Basis
is the type of day count to use. @Basis is an expression of the character string data type category.
Return Type
float
Remarks
· If @Yld < 0 or if @Rate < 0, DURATION returns an error
· If the @Frequency is any number other than 1, 2, 4, or 12, DURATION returns an error
· If @Settlement > @Maturity, DURATION returns an error
· If the @Basis < 0 or the @Basis > 4, DURATION returns an error
Example
SELECT wct.DURATION ('12/22/2007'
,'12/15/2009'
,0.05
,0.06
,2
,0)
Here is the result set
----------------------
1.90779125985842
XLeratorDB Blog examples
25
Summary
XLeratorDB Summary