yearfrac: Year Fruction for Rust
It was tested to match Excel's YEARFRAC function and with time go beyond. We support all 5 Excel's methodologies: nasd360 act/act act360 act365 eur360
Usage
Put this in your Cargo.toml:
[]
= "0.1"
Examples
use DayCountConvention;
use ;
let start = from_ymd;
let end = from_ymd;
let yf = from_int.unwrap
.yearfrac;
assert!;
let yf = from_str.unwrap
.yearfrac;
assert!;
use is_leap_year;
assert_eq!