Skip to content

Commit

Permalink
Preparing for CRAN and switching to wdm instead of pcaPP
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexisDerumigny committed Apr 25, 2022
1 parent 8c9b9a3 commit a2b46db
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 7 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ Depends:
Imports:
VineCopula,
cubature,
pcaPP,
randtoolbox,
pbapply
pbapply,
wdm
Suggests:
knitr,
rmarkdown
Expand Down
1 change: 1 addition & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@

* Fixed the documentation of the parameter `kernel` for the functions `BiCopEstMMD` and `BiCopGradMMD`.

* New dependence `wdm` instead of `pcaPP` for fast computation of Kendall's tau.


# MMDCopula 0.2.0
Expand Down
4 changes: 2 additions & 2 deletions R/BiCopEstMMD.R
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ BiCopEstMMD <- function(
niter = rep(niter, length.out = 2)
if (is.null(tau)){
# We try a random guess
# tau = pcaPP::cor.fk(u1, u2)
# tau = wdm::wdm(u1, u2, method = "kendall")
if (family %in% c(1, 5, 6,16,26,36)){
tau = stats::runif(n = 1, min = -0.95, max = 0.95)
} else if (family %in% c(3, 23, 4, 24)){
Expand Down Expand Up @@ -290,7 +290,7 @@ BiCopEstMMD.QMCV.student <- function(
kernelFun, gamma, alpha, epsilon,
quasiRNGFun, ndrawings, niter, C_eta)
{
par = VineCopula::BiCopTau2Par(family = 2, tau = pcaPP::cor.fk(u1, u2))
par = VineCopula::BiCopTau2Par(family = 2, tau = wdm::wdm(u1, u2, method = "kendall"))

# 1- Burn-in phase
paramIter = c(par, par2)
Expand Down
2 changes: 1 addition & 1 deletion R/MarshallOlkin.R
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ BiCopEst.MO.curve = function(u1,u2)
# based on the inversion of Kendall's tau
BiCopEst.MO.itau = function(u1,u2)
{
tau = pcaPP::cor.fk(u1, u2)
tau = wdm::wdm(u1, u2, method = "kendall")
return(list(tau = tau, par = 2*tau/(1+tau)))
}

Expand Down
4 changes: 2 additions & 2 deletions cran-comments.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@

## Test environments

* Windows 10 (devel, release)
* Windows 10 (release)
* Windows Server 2022 (devel)
* Fedora Linux (devel)
* Debian Linux (devel)
* Ubuntu Linux (release)
* macOS High Sierra (release)

Expand Down

0 comments on commit a2b46db

Please sign in to comment.