interpolation_pairs: Get interpolation pairs for the yields, maturity dates and...

Description Usage Arguments Value Examples

View source: R/interpolation-pairs.R

Description

Get interpolation pairs for the yields, maturity dates and tenors.

Usage

1
interpolation_pairs(retrieval_date, wal_date, maturity_dt, yields_dt)

Arguments

retrieval_date

Retrieval (anchor) date.

wal_date

Weighted average life as a date.

maturity_dt

Datatable of maturity of each (CAD curve) tenor.

yields_dt

Datatable of yield of each (CAD curve) tenor.

Value

yields Yields of short and long tenor to interpolate between.

Examples

1
2
3
4
5
6
7
retrieval_date <- lubridate::ymd( "2013-03-01" )
wal_date <- lubridate::ymd( "2014-06-21" )
data( bloomberg_goc, package = "blpxl" )
data( bloomberg_cad_maturity, package = "blpxl" )
list_args_pt1 <- list( wal_date = wal_date, retrieval_date = retrieval_date )
list_args_pt2 <- list( maturity_dt = bloomberg_cad_maturity, yields_dt = bloomberg_goc )
do.call( interpolation_pairs, args = c( list_args_pt1, list_args_pt2 ) )

vathymut/indemnity documentation built on May 3, 2019, 4:35 p.m.