From 6442dca4084f5b6b701896ff8c891c4cda8b9b92 Mon Sep 17 00:00:00 2001 From: farzadwp <36614630+farzadwp@users.noreply.github.com> Date: Wed, 27 Nov 2019 16:28:57 +1100 Subject: [PATCH] updating from upstream --- DESCRIPTION | 50 ++++++++++++++------------ NAMESPACE | 69 ++++++------------------------------ man/interpolate.Rd | 6 ++-- man/interpolate.ZeroCurve.Rd | 8 ++--- man/interpolate_dfs.Rd | 15 +++----- man/interpolate_zeros.Rd | 14 +++----- 6 files changed, 54 insertions(+), 108 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 521e18c..7beb413 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,32 +1,38 @@ Type: Package Package: fmbasics Title: Financial Market Building Blocks -Version: 0.3.0 -Authors@R: person("Imanuel", "Costigan", email = "i.costigan@me.com", - role = c("aut", "cre")) -Description: Implements basic financial market objects like currencies, currency - pairs, interest rates and interest rate indices. You will be able to use - Benchmark instances of these objects which have been defined using their most - common conventions or those defined by International Swap Dealer Association - (ISDA, ) legal documentation. +Version: 0.3.99 +Authors@R: c(person(given = "Imanuel", family = "Costigan", role = c("aut", "cre"), + email = "i.costigan@me.com"), + person(given = "Sayf", family = "Hamada", role = "ctb", + email = "sayfeddine.hamada@westpac.com.au")) +Description: Implements basic financial market objects like + currencies, currency pairs, interest rates and interest rate indices. + You will be able to use Benchmark instances of these objects which + have been defined using their most common conventions or those defined + by International Swap Dealer Association (ISDA, + ) legal documentation. License: GPL-2 -URL: https://github.com/imanuelcostigan/fmbasics, https://imanuelcostigan.github.io/fmbasics/ +URL: https://github.com/imanuelcostigan/fmbasics, + https://imanuelcostigan.github.io/fmbasics/ BugReports: https://github.com/imanuelcostigan/fmbasics/issues Imports: - assertthat, - fmdates (>= 0.1.2), - lubridate (>= 1.6.0), - methods, - stats, - tibble, - utils, - credule + assertthat, + fmdates (>= 0.1.2), + lubridate (>= 1.6.0), + methods, + readr, + stats, + tibble, + utils, + tidyr Suggests: - covr, - knitr, - rmarkdown, - testthat -VignetteBuilder: knitr + covr, + knitr, + rmarkdown, + testthat +VignetteBuilder: + knitr Encoding: UTF-8 LazyData: true Roxygen: list(markdown = TRUE) diff --git a/NAMESPACE b/NAMESPACE index 5b2f879..252b4ad 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -2,60 +2,33 @@ S3method("!=",DiscountFactor) S3method("!=",InterestRate) -S3method("!=",SurvivalProbabilities) -S3method("!=",ZeroHazardRate) S3method("<",DiscountFactor) S3method("<",InterestRate) -S3method("<",SurvivalProbabilities) -S3method("<",ZeroHazardRate) S3method("<=",DiscountFactor) S3method("<=",InterestRate) -S3method("<=",SurvivalProbabilities) -S3method("<=",ZeroHazardRate) S3method("==",DiscountFactor) S3method("==",InterestRate) -S3method("==",SurvivalProbabilities) -S3method("==",ZeroHazardRate) S3method(">",InterestRate) -S3method(">",ZeroHazardRate) S3method(">=",DiscountFactor) S3method(">=",InterestRate) -S3method(">=",SurvivalProbabilities) -S3method(">=",ZeroHazardRate) S3method("[",DiscountFactor) S3method("[",InterestRate) -S3method("[",SurvivalProbabilities) -S3method("[",ZeroHazardRate) S3method("[<-",DiscountFactor) S3method("[<-",InterestRate) -S3method("[<-",SurvivalProbabilities) -S3method("[<-",ZeroHazardRate) S3method(all.equal,InterestRate) -S3method(all.equal,ZeroHazardRate) S3method(as.character,Currency) S3method(as.double,DiscountFactor) S3method(as.double,InterestRate) S3method(as_DiscountFactor,InterestRate) S3method(as_InterestRate,DiscountFactor) S3method(as_InterestRate,InterestRate) -S3method(as_SurvivalProbabilities,ZeroHazardRate) -S3method(as_ZeroHazardRate,SurvivalProbabilities) -S3method(as_ZeroHazardRate,ZeroHazardRate) S3method(as_tibble,CashFlow) -S3method(as_tibble,CreditCurve) S3method(as_tibble,MultiCurrencyMoney) S3method(as_tibble,ZeroCurve) S3method(c,DiscountFactor) S3method(c,InterestRate) S3method(c,SingleCurrencyMoney) -S3method(c,SurvivalProbabilities) -S3method(c,ZeroHazardRate) -S3method(format,CDSCurve) -S3method(format,CDSMarkitSpec) -S3method(format,CDSSingleNameSpec) -S3method(format,CDSSpec) S3method(format,CashIndex) -S3method(format,CreditCurve) S3method(format,Currency) S3method(format,CurrencyPair) S3method(format,DiscountFactor) @@ -63,16 +36,12 @@ S3method(format,IborIndex) S3method(format,InterestRate) S3method(format,Interpolation) S3method(format,SingleCurrencyMoney) -S3method(format,SurvivalProbabilities) +S3method(format,VolSurface) S3method(format,ZeroCurve) -S3method(format,ZeroHazardRate) -S3method(interpolate,CreditCurve) +S3method(interpolate,VolSurface) S3method(interpolate,ZeroCurve) -S3method(interpolate_dfs,CreditCurve) S3method(interpolate_dfs,ZeroCurve) -S3method(interpolate_fwds,CreditCurve) S3method(interpolate_fwds,ZeroCurve) -S3method(interpolate_zeros,CreditCurve) S3method(interpolate_zeros,ZeroCurve) S3method(iso,CashIndex) S3method(iso,CurrencyPair) @@ -81,15 +50,8 @@ S3method(iso,SingleCurrencyMoney) S3method(iso,default) S3method(length,DiscountFactor) S3method(length,InterestRate) -S3method(length,SurvivalProbabilities) -S3method(length,ZeroHazardRate) S3method(locale,Currency) S3method(locale,CurrencyPair) -S3method(print,CDSCurve) -S3method(print,CDSMarkitSpec) -S3method(print,CDSSingleNameSpec) -S3method(print,CDSSpec) -S3method(print,CreditCurve) S3method(print,Currency) S3method(print,CurrencyPair) S3method(print,DiscountFactor) @@ -97,13 +59,10 @@ S3method(print,Index) S3method(print,InterestRate) S3method(print,Interpolation) S3method(print,SingleCurrencyMoney) -S3method(print,SurvivalProbabilities) +S3method(print,VolSurface) S3method(print,ZeroCurve) -S3method(print,ZeroHazardRate) S3method(rep,DiscountFactor) S3method(rep,InterestRate) -S3method(rep,SurvivalProbabilities) -S3method(rep,ZeroHazardRate) S3method(tbl_sum,CashFlow) S3method(tbl_sum,MultiCurrencyMoney) S3method(to_maturity,default) @@ -118,17 +77,12 @@ export(AUDBBSW) export(AUDBBSW1b) export(AUDNZD) export(AUDUSD) -export(CDSCurve) -export(CDSMarkitSpec) -export(CDSSingleNameSpec) -export(CDSSpec) export(CHF) export(CHFLIBOR) export(CHFTOIS) export(CashFlow) export(CashIndex) export(ConstantInterpolation) -export(CreditCurve) export(CubicInterpolation) export(Currency) export(CurrencyPair) @@ -153,6 +107,7 @@ export(InterestRate) export(JPY) export(JPYLIBOR) export(JPYTIBOR) +export(LinearCubicTimeVarInterpolation) export(LinearInterpolation) export(LogDFInterpolation) export(MultiCurrencyMoney) @@ -164,7 +119,6 @@ export(NZDUSD) export(NZIONA) export(SONIA) export(SingleCurrencyMoney) -export(SurvivalProbabilities) export(TONAR) export(USD) export(USDCHF) @@ -172,24 +126,22 @@ export(USDHKD) export(USDJPY) export(USDLIBOR) export(USDNOK) +export(VolQuotes) +export(VolSurface) export(ZeroCurve) -export(ZeroHazardRate) export(as_DiscountFactor) export(as_InterestRate) -export(as_SurvivalProbabilities) -export(as_ZeroHazardRate) +export(build_vol_quotes) +export(build_vol_surface) export(build_zero_curve) export(interpolate) export(interpolate_dfs) export(interpolate_fwds) export(interpolate_zeros) export(invert) -export(is.CDSCurve) -export(is.CDSSpec) export(is.CashFlow) export(is.CashIndex) export(is.ConstantInterpolation) -export(is.CreditCurve) export(is.CubicInterpolation) export(is.Currency) export(is.CurrencyPair) @@ -198,13 +150,14 @@ export(is.IborIndex) export(is.Index) export(is.InterestRate) export(is.Interpolation) +export(is.LinearCubicTimeVarInterpolation) export(is.LinearInterpolation) export(is.LogDFInterpolation) export(is.MultiCurrencyMoney) export(is.SingleCurrencyMoney) -export(is.SurvivalProbabilities) +export(is.VolQuotes) +export(is.VolSurface) export(is.ZeroCurve) -export(is.ZeroHazardRate) export(is_t1) export(iso) export(to_forward) diff --git a/man/interpolate.Rd b/man/interpolate.Rd index 1ecf79e..d777e8b 100644 --- a/man/interpolate.Rd +++ b/man/interpolate.Rd @@ -18,9 +18,9 @@ an interpolated value or set of values Interpolate values from an object } \seealso{ -Other interpolate functions: \code{\link{interpolate.CreditCurve}}, +Other interpolate functions: \code{\link{interpolate.VolSurface}}, \code{\link{interpolate.ZeroCurve}}, - \code{\link{interpolate_dfs.CreditCurve}}, - \code{\link{interpolate_zeros.CreditCurve}} + \code{\link{interpolate_dfs}}, + \code{\link{interpolate_zeros}} } \concept{interpolate functions} diff --git a/man/interpolate.ZeroCurve.Rd b/man/interpolate.ZeroCurve.Rd index a400adc..2c30da9 100644 --- a/man/interpolate.ZeroCurve.Rd +++ b/man/interpolate.ZeroCurve.Rd @@ -1,5 +1,5 @@ % Generated by roxygen2: do not edit by hand -% Please edit documentation in R/zero-curve-class.R +% Please edit documentation in R/interpolation-class.R \name{interpolate.ZeroCurve} \alias{interpolate.ZeroCurve} \title{Interpolate a \code{ZeroCurve}} @@ -30,9 +30,9 @@ zc <- build_zero_curve(LogDFInterpolation()) interpolate(zc, c(1.5, 3)) } \seealso{ -Other interpolate functions: \code{\link{interpolate.CreditCurve}}, - \code{\link{interpolate_dfs.CreditCurve}}, - \code{\link{interpolate_zeros.CreditCurve}}, +Other interpolate functions: \code{\link{interpolate.VolSurface}}, + \code{\link{interpolate_dfs}}, + \code{\link{interpolate_zeros}}, \code{\link{interpolate}} } \concept{interpolate functions} diff --git a/man/interpolate_dfs.Rd b/man/interpolate_dfs.Rd index a0252a4..6255db9 100644 --- a/man/interpolate_dfs.Rd +++ b/man/interpolate_dfs.Rd @@ -1,19 +1,12 @@ % Generated by roxygen2: do not edit by hand -% Please edit documentation in R/credit-class.R, R/generic-methods.R, -% R/zero-curve-class.R -\name{interpolate_dfs.CreditCurve} -\alias{interpolate_dfs.CreditCurve} -\alias{interpolate_fwds.CreditCurve} +% Please edit documentation in R/generic-methods.R, R/interpolation-class.R +\name{interpolate_dfs} \alias{interpolate_dfs} \alias{interpolate_fwds} \alias{interpolate_fwds.ZeroCurve} \alias{interpolate_dfs.ZeroCurve} \title{Interpolate forward rates and discount factors} \usage{ -\method{interpolate_dfs}{CreditCurve}(x, from, to, ...) - -\method{interpolate_fwds}{CreditCurve}(x, from, to, ...) - interpolate_dfs(x, from, to, ...) interpolate_fwds(x, from, to, ...) @@ -42,9 +35,9 @@ This interpolates forward rates and forward discount factors from either a \link[=ZeroCurve]{ZeroCurve} or some other object that contains such an object. } \seealso{ -Other interpolate functions: \code{\link{interpolate.CreditCurve}}, +Other interpolate functions: \code{\link{interpolate.VolSurface}}, \code{\link{interpolate.ZeroCurve}}, - \code{\link{interpolate_zeros.CreditCurve}}, + \code{\link{interpolate_zeros}}, \code{\link{interpolate}} } \concept{interpolate functions} diff --git a/man/interpolate_zeros.Rd b/man/interpolate_zeros.Rd index 8285b44..a84c772 100644 --- a/man/interpolate_zeros.Rd +++ b/man/interpolate_zeros.Rd @@ -1,15 +1,10 @@ % Generated by roxygen2: do not edit by hand -% Please edit documentation in R/credit-class.R, R/generic-methods.R, -% R/zero-curve-class.R -\name{interpolate_zeros.CreditCurve} -\alias{interpolate_zeros.CreditCurve} +% Please edit documentation in R/generic-methods.R, R/interpolation-class.R +\name{interpolate_zeros} \alias{interpolate_zeros} \alias{interpolate_zeros.ZeroCurve} \title{Interpolate zeros} \usage{ -\method{interpolate_zeros}{CreditCurve}(x, at, compounding = NULL, - day_basis = NULL, ...) - interpolate_zeros(x, at, compounding = NULL, day_basis = NULL, ...) \method{interpolate_zeros}{ZeroCurve}(x, at, compounding = NULL, @@ -38,9 +33,8 @@ This interpolates zero rates from either a \link[=ZeroCurve]{ZeroCurve} or some other object that contains such an object. } \seealso{ -Other interpolate functions: \code{\link{interpolate.CreditCurve}}, +Other interpolate functions: \code{\link{interpolate.VolSurface}}, \code{\link{interpolate.ZeroCurve}}, - \code{\link{interpolate_dfs.CreditCurve}}, - \code{\link{interpolate}} + \code{\link{interpolate_dfs}}, \code{\link{interpolate}} } \concept{interpolate functions}