Manuals/calci/YEARFRAC

From ZCubes Wiki
Revision as of 21:47, 24 October 2013 by MassBot1 (talk | contribs) (Created page with "<div id="6SpaceContent" class="zcontent" align="left"> '''YEARFRAC'''(SomeFrom, SomeTo, SomeBasis) where, '''SomeFrom''' - is a date that represents the start date. ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

YEARFRAC(SomeFrom, SomeTo, SomeBasis)

where,

SomeFrom - is a date that represents the start date.

SomeTo - is a date that represents the end date.

SomeBasis - is the type of day count

Basis           Day count

0                 US 30/360

1                 Actual/actual

2                 Actual/360

3                 Actual/365

4                 European 30/360


Calci calculates the fraction of the year between startdate and enddate.


All parameters are truncated to integers.

If SomeBasis < 0 or SomeBasis > 4, YEARFRAC

returns the #ERROR.


YEARFRAC


Lets see an example in (Column1, Row4)

=YEARFRAC(R1C1,R2C2,R3C1)

YEARFRAC returns 0.766667

consider an another example

=YEARFRAC(DATE(2008,5,4),DATE(2008,6,4),-4)

YEARFRAC returns #ERROR.


Syntax

Remarks

Examples

Description

Column1 Column2 Column3 Column4
Row1 1/4/2008
Row2 10/10/2008
Row3 4
Row4 0.766667
Row5
Row6