Financial Toolbox
  Go to function:
    Search    Help Desk 
yearfrac    Examples   See Also

Fraction of year between dates.

Syntax

Description

f = yearfrac(d1, d2, basis) returns a fraction based on the number days between dates d1 and d2 using the given day-count basis. If d2 is earlier than d1, f is negative. Enter dates as serial date numbers or date strings.

basis is the day-count basis: 0 = actual/actual (default), 1 = 30/360,
2 = actual/360, 3 = actual/365.

Examples

See Also

days360, days365, daysact, daysdif, months, wrkdydif, yeardays



[ Previous | Help Desk | Next ]