From c04e11cc7cd445c1a0b33c16b8e77ab985d9d870 Mon Sep 17 00:00:00 2001
From: Laurent Modolo <laurent.modolo@ens-lyon.fr>
Date: Wed, 24 Aug 2022 10:51:00 +0200
Subject: [PATCH] add idr main function and fix warning in *.Rd

---
 NAMESPACE                            |  1 +
 R/main.R                             | 62 ++++++++++++++++++++++++----
 R/plots.R                            |  4 +-
 R/pseudo_data.R                      | 14 +++++--
 README.md                            | 54 ++++++++++++------------
 man/compute_idr.Rd                   | 13 +++---
 man/fit_mixture.Rd                   |  2 +
 man/gatherpairs.Rd                   |  4 +-
 man/idr.Rd                           | 45 ++++++++++++++++++++
 man/mono_fit_mixture.Rd              |  2 +
 man/mono_fit_mixture_arch.Rd         |  4 +-
 man/prod_pseudo_copula_mixture.Rd    |  2 +-
 man/prod_pseudo_marginal.Rd          |  4 +-
 man/pseudo_compute_idr.Rd            |  2 -
 man/pseudo_copula_mixture.Rd         |  2 +
 man/pseudo_fit_marginal.Rd           |  2 +
 man/pseudo_likelihood_fit_mixture.Rd |  4 ++
 man/pseudo_local_idr.Rd              |  2 +
 man/pseudo_rename_params.Rd          |  2 +
 man/pseudo_rename_theta.Rd           |  2 +
 man/pseudo_rename_weight.Rd          |  2 +
 21 files changed, 176 insertions(+), 53 deletions(-)
 create mode 100644 man/idr.Rd

diff --git a/NAMESPACE b/NAMESPACE
index e97a125..1fcdc7c 100644
--- a/NAMESPACE
+++ b/NAMESPACE
@@ -7,6 +7,7 @@ export(copula_mixture)
 export(copula_mixture_arch)
 export(fit_mixture)
 export(fixed_rank)
+export(idr)
 export(idr_hist)
 export(is_idr)
 export(pairs_plot)
diff --git a/R/main.R b/R/main.R
index 25073d5..295e099 100644
--- a/R/main.R
+++ b/R/main.R
@@ -294,6 +294,7 @@ copula_mixture_arch <- function(
 #' @param optim_method (default: \code{mpl}) the fitting method
 #' @param prop (default: \code{1.}) faction of the data to use for estimation
 #' @param method (default: \code{"arch"}), use the samic or originial gaussian model \code{c("arch", "gaussian", "emp")}
+#' @param estimate the results of \code{pseudo_likelihood_fit_mixture(data)}
 #' @param init (default: \code{c(copula_mixture_theta(samic), copula_mixture_weight(samic))}), starting set of parameters
 #' @return a \code{fitCopula} object of the \code{copula} package
 #' @examples
@@ -328,7 +329,7 @@ mono_fit_mixture <- function(u, optim_method = "mpl", prop = 1., method = "arch"
 #' @param K a vector of IDR probability
 #' @param L a matrix of Archimedean copula mixture probabilities
 #' @param estimate a vector or mode parameters
-#' @param optim method (default: \code{mpl}) the fitting method
+#' @param optim_method (default: \code{mpl}) the fitting method
 #' @param prop (default: \code{1.}) faction of the data to use for estimation
 #' @param method (default: \code{"arch"}), use the samic or originial gaussian model \code{c("arch", "gaussian", "emp")}
 #' @return a \code{fitCopula} object of the \code{copula} package
@@ -374,7 +375,6 @@ mono_fit_mixture_arch <- function(u, K, L, estimate, optim_method = "L-BFGS-B",
 #' @param data (default: \code{NULL}) a matrix of data values (with sample as column)
 #' @param u (default: \code{NULL}) a matrix of rank values (with sample as column)
 #' @param optim_method (default: \code{mpl}) the fitting method
-#' @param method (default: \code{mpl}) the fitting method
 #' @param thread (default: \code{1}) number of cpus to use for estimation
 #' @param skip_zero (default: \code{FALSE}) should the zeros contribute to
 #' the empirical cumulative distribution ?
@@ -382,6 +382,7 @@ mono_fit_mixture_arch <- function(u, K, L, estimate, optim_method = "L-BFGS-B",
 #' between the rank and the rank + 1
 #' @param prop (default: \code{1.}) faction of the data to use for estimation
 #' @param method (default: \code{"arch"}), use the samic or originial gaussian model \code{c("arch", "gaussian", "emp")}
+#' @param estimate list of parameters values
 #' @param two_step (default: \code{F}) **experimental** alternative fitting procedure
 #' @return a \code{fitCopula} object of the \code{copula} package
 #' @examples
@@ -534,8 +535,9 @@ two_step_fit_mixture <- function(
 
 #' Compte the IDR
 #'
-#' @param data (default: \code{NULL}) a matrix of data values (with sample as column)
-#' @param u (default: \code{NULL}) a matrix of rank values (with sample as column)
+#' @param data (default: \code{NULL}) a tibble of data values (with sample as column)
+#' @param u (default: \code{NULL}) a matrix of rank values (with sample as
+#' column)
 #' @param estimate the results of \code{fit_mixture(u)}
 #' @param thread (default: \code{1}) number of cpus to use for estimation
 #' @param skip_zero (default: \code{FALSE}) should the zeros contribute to
@@ -556,8 +558,8 @@ two_step_fit_mixture <- function(
 #' @export
 compute_idr <- function(
     data = NULL, u = NULL, estimate = NULL, thread = 1, prop = 1.,
-    skip_zero = F, randomize = F, method = "arch", two_step = F,
-    verbose = F) {
+    skip_zero = FALSE, randomize = FALSE, method = "arch", two_step = FALSE,
+    verbose = FALSE) {
   estimate =  fit_mixture(
     data = data, thread = thread, prop = prop, skip_zero = skip_zero,
     randomize = randomize, method = method, two_step = two_step, estimate = estimate)
@@ -587,4 +589,50 @@ compute_idr <- function(
 }
 
 
-
+#' Compte the IDR
+#'
+#' @param data (default: \code{NULL}) a matrix of data values (with sample as
+#' column)
+#' @param estimate the results of \code{pseudo_likelihood_fit_mixture(data)}
+#' @param method (default: \code{"arch"}), use the samic or originial gaussian
+#' model \code{c("arch", "gaussian", "emp")}
+#' @param type (default: \code{"pseudo"}), perform classical IDR computation or
+#' computation without the hypothesis that lower score are less reproducible
+#' (for testing only) \code{c("pseudo", "direct")}
+#' @param eps (default: \code{1e-3}), threshold of the precision of the
+#' optimisation
+#' @param verbose (default: \code{F}) print messages
+#' @return a list of a vector of idr values of size \code{nrow(u)} and a list
+#' of estimate values
+#' @examples
+#' \dontrun{
+#' idr(data)
+#' }
+#' @export
+idr <- function(data = NULL, estimate = NULL, eps = 1e-3, method = "arch",
+    type = "pseudo", verbose = FALSE
+  ) {
+  if (type == "pseudo") {
+    return(
+      pseudo_compute_idr(
+        data = data, method = method, estimate = estimate, eps = eps,
+        verbose = verbose
+      )
+    )
+  } else {
+    return(
+      compute_idr(
+        data = data,
+        u = NULL,
+        estimate = NULL,
+        thread = 1,
+        prop = 1.,
+        skip_zero = FALSE,
+        randomize = FALSE,
+        method = method,
+        two_step = FALSE,
+        verbose = verbose
+      )
+    )
+  }
+}
diff --git a/R/plots.R b/R/plots.R
index 368ff9b..7ddd1a6 100644
--- a/R/plots.R
+++ b/R/plots.R
@@ -5,8 +5,8 @@
 #' @param ... list of column to represent on 2 dimension 2 by 2
 #' @param xkey name of the column for x names
 #' @param xvalue name of the column for x values
-#' @param ykey name of the column for x names
-#' @param yvalue name of the column for x values
+#' @param ykey name of the column for x names @param yvalue name of the column for x values
+#' @param yvalue name of the column for y values
 #' @param na.rm (default: \code{FALSE}) should \code{NA} values be removed
 #' @param convert If \code{TRUE} will automatically run \code{type.convert()}
 #' on the key column. This is useful if the column types are actually numeric,
diff --git a/R/pseudo_data.R b/R/pseudo_data.R
index 094f18c..4383572 100644
--- a/R/pseudo_data.R
+++ b/R/pseudo_data.R
@@ -157,6 +157,7 @@ pseudo_upper_bound_params <- function(method){
 #' Helper function for \code{fit_mixture} function
 #' Return a named vector of values for parameters and weights
 #' for the models from a unnamed vectors
+#' @param params named vector of model parameters 
 #' @param method (default: \code{"arch"}), use the samic or originial gaussian model
 #' @return The sum of \code{x} and \code{y}.
 #' @examples
@@ -187,6 +188,7 @@ pseudo_rename_params <- function(params, method = "arch") {
 #' Helper function for \code{fit_mixture} function
 #' Return a named vector of values for parameters
 #' for the models from a unnamed vectors
+#' @param theta named vector of theta values
 #' @param method (default: \code{"arch"}), use the samic or originial gaussian model
 #' @return The sum of \code{x} and \code{y}.
 #' @examples
@@ -216,6 +218,7 @@ pseudo_rename_theta <- function(theta, method = "arch") {
 #' Helper function for \code{fit_mixture} function
 #' Return a named vector of values for weights
 #' for the models from a unnamed vectors
+#' @param weight named vector of weight values
 #' @param method (default: \code{"arch"}), use the samic or originial gaussian model
 #' @return The sum of \code{x} and \code{y}.
 #' @examples
@@ -248,6 +251,7 @@ pseudo_rename_weight <- function(weight, method = "arche") {
 
 #' Helper function for \code{fit_mixture} and \code{compute_idr} function
 #'
+#' @param u (default: \code{NULL}) a matrix of rank values (with sample as column)
 #' @param theta (defaut: \code{copula_mixture_theta()} a named vector of theta
 #' values as generated by the \code{copula_mixture_theta()} function
 #' @param weight (defaut: \code{copula_mixture_weight()} a named vector of weight
@@ -300,7 +304,7 @@ pseudo_copula_mixture <- function(u, theta = copula_mixture_theta(),
 #' @param L for \code{samic = T} a matrix of size \code{ncol(u) * 3} for archimean
 #' copula weight
 #' @param u a matrix of pseudo-rank
-#' @param method (default: \code{"arch"}), use the samic or originial gaussian model
+#' @param fn_method (default: \code{"arch"}), use the samic or originial gaussian model
 #' @return the log-likelihood of the copula mixture model given the data
 #' @examples
 #' \dontrun{
@@ -353,11 +357,12 @@ prod_pseudo_copula_mixture <- function(
 
 #' Helper function for \code{fit_mixture} and \code{compute_idr} function
 #'
+#' @param u (default: \code{NULL}) a matrix of rank values (with sample as column)
 #' @param params a named vector of variables model parameters
 #' @param estimate a named vector of all the model parameters
 #' @param K a vector of indep probability of size \code{ncol(z)}
 #' @param z a matrix of pseudo-values
-#' @param method (default: \code{"arch"}), use the samic or originial gaussian model
+#' @param fn_method (default: \code{"arch"}), use the samic or originial gaussian model
 #' @return the log-likelihood of the marginal mixture model given the data
 #' @examples
 #' \dontrun{
@@ -566,6 +571,7 @@ pseudo_proba_archs <- function(
 #' Helper function for \code{fit_mixture} and \code{compute_idr} function
 #'
 #' @param z a matrix of pseudo-values
+#' @param u (default: \code{NULL}) a matrix of rank values (with sample as column)
 #' @param K a vector of indep probability of size \code{ncol(z)}
 #' @param L for \code{samic = T} a matrix of size \code{ncol(z) * 3} for archimean
 #' copula weight
@@ -758,6 +764,8 @@ qnorm_mix <- function(u, pmix = 0.5, mu = 4, sd1 = 1, sd2 = 1) {
 #' @param data (default: \code{NULL}) a matrix of data values (with sample as column)
 #' @param method (default: \code{"arch"}) use the samic or originial gaussian model
 #' @param eps (default: \code{1e-3}), threshold of the precision of the optimisation
+#' @param fixed_estimate the results of \code{pseudo_likelihood_fit_mixture(data)}
+#' @param verbose (default: \code{F}) print messages
 #' @return a \code{fitCopula} object of the \code{copula} package
 #' @examples
 #' \dontrun{
@@ -831,6 +839,7 @@ pseudo_likelihood_fit_mixture <- function(
 #' @param u (default: \code{NULL}) a matrix of rank values (with sample as column)
 #' @param estimate the results of \code{fit_mixture(u)}
 #' @param method (default: \code{"arch"}), use the samic or originial gaussian model
+#' @param verbose (default: \code{F}) print messages
 #' @return a vector of idr values of size \code{nrow(u)}
 #' @examples
 #' \dontrun{
@@ -865,7 +874,6 @@ pseudo_local_idr <- function(
 #' Compte the IDR
 #'
 #' @param data (default: \code{NULL}) a matrix of data values (with sample as column)
-#' @param u (default: \code{NULL}) a matrix of rank values (with sample as column)
 #' @param estimate the results of \code{pseudo_likelihood_fit_mixture(data)}
 #' @param method (default: \code{"arch"}), use the samic or originial gaussian model \code{c("arch", "gaussian", "emp")}
 #' @param eps (default: \code{1e-3}), threshold of the precision of the optimisation
diff --git a/README.md b/README.md
index b4d80e5..4fee3d5 100644
--- a/README.md
+++ b/README.md
@@ -18,7 +18,7 @@ These instructions will get you a copy of the project up and running on your loc
 
 To run **midr** on your computer you need to have R (\>= 4.1.0) installed and the `devtools` package.
 
-``` sh
+```sh
 install.packages("remotes")
 ```
 
@@ -26,13 +26,13 @@ install.packages("remotes")
 
 To easily install **midr** on your computer using `devtools` run the following command:
 
-``` r
+```r
 remotes::install_git("https://gitbio.ens-lyon.fr/LBMC/sbdm/idr")
 ```
 
 Check the vignette:
 
-``` r
+```r
 library(midr)
 devtools::build_vignettes("midr")
 browseVignettes("midr")
@@ -42,29 +42,29 @@ browseVignettes("midr")
 
 The **idr** package depends on the following R library:
 
--   `copula` (\>= 1.0-1),
--   `rtracklayer` (\>= 1.54.0),
--   `GenomicRanges` (\>= 1.46.1),
--   `S4Vectors` (\>= 0.32.2),
--   `dplyr` (\>= 1.0.7),
--   `ggplot2` (\>= 3.3.5),
--   `stringr` (\>= 1.4.0),
--   `tibble` (\>= 3.1.6),
--   `tidyr` (\>= 1.1.4),
--   `purrr` (\>= 0.3.4),
--   `tidyselect` (\>= 1.1.1),
--   `parallel` (\>= 4.1.2),
--   `GoFKernel` (\>= 2.1)
+- `copula` (\>= 1.0-1),
+- `rtracklayer` (\>= 1.54.0),
+- `GenomicRanges` (\>= 1.46.1),
+- `S4Vectors` (\>= 0.32.2),
+- `dplyr` (\>= 1.0.7),
+- `ggplot2` (\>= 3.3.5),
+- `stringr` (\>= 1.4.0),
+- `tibble` (\>= 3.1.6),
+- `tidyr` (\>= 1.1.4),
+- `purrr` (\>= 0.3.4),
+- `tidyselect` (\>= 1.1.1),
+- `parallel` (\>= 4.1.2),
+- `GoFKernel` (\>= 2.1)
 
 ## Usage
 
-**idr** Takes as input files in the [NarrowPeaks format](https://genome.ucsc.edu/FAQ/FAQformat.html#format12), and output NarrowPeaks files with an additional *idr* column.
+**idr** Takes as input files in the [NarrowPeaks format](https://genome.ucsc.edu/FAQ/FAQformat.html#format12), and output NarrowPeaks files with an additional _idr_ column.
 
-Computing *IDR* between three replicates
+Computing _IDR_ between three replicates
 
 We can start with a matrix of values with the replicates as columns and the positions as rows or load bed files with the following command:
 
-``` r
+```r
 # load the initial data
 data <- bed_to_matrix(
   "merged_peak_calling.NarrowPeaks",
@@ -78,36 +78,36 @@ Where `replicate1_.NarrowPeaks` is the output of the peak caller on the alignmen
 
 Then we can compute the IDR of each row with the following commands.
 
-``` r
+```r
 # compute the IDR
-idr <- compute_idr(data, thread = 8)
+idr <- idr(data)
 ```
 
-If you want to work under the hypothesis that lower values in your data are less reproducible than higher value you can use instead the `pseudo_compute_idr()` function.
+If you don't want to work under the hypothesis that lower values in your data are less reproducible than higher value you can use instead the `type = "direct" option.
 
-``` r
+```r
 # compute the IDR
-idr <- pseudo_compute_idr(data)
+idr <- idr(data, type = "direct")
 ```
 
 The default `samic = T` option use a flexible mixture of 3 Archimedean copula (Gumbel, Clayton and Frank), while the `samic = F` use a Gaussian copula model.
 
 To see the histogram of IDR at an `alpha` level:
 
-``` r
+```r
 idr_hist(idr, alpha = 0.05)
 ```
 
 You can then display the results on the `data` or `u` space
 
-``` r
+```r
 pairs_plot(u, idr, alpha = 0.05)
 pairs_plot(data, idr, alpha = 0.05, scale_log = T)
 ```
 
 ## Authors
 
--   **Laurent Modolo** - *Initial work*
+- **Laurent Modolo** - _Initial work_
 
 ## License
 
diff --git a/man/compute_idr.Rd b/man/compute_idr.Rd
index fa383f7..35b1685 100644
--- a/man/compute_idr.Rd
+++ b/man/compute_idr.Rd
@@ -10,17 +10,18 @@ compute_idr(
   estimate = NULL,
   thread = 1,
   prop = 1,
-  skip_zero = F,
-  randomize = F,
+  skip_zero = FALSE,
+  randomize = FALSE,
   method = "arch",
-  two_step = F,
-  verbose = F
+  two_step = FALSE,
+  verbose = FALSE
 )
 }
 \arguments{
-\item{data}{(default: \code{NULL}) a matrix of data values (with sample as column)}
+\item{data}{(default: \code{NULL}) a tibble of data values (with sample as column)}
 
-\item{u}{(default: \code{NULL}) a matrix of rank values (with sample as column)}
+\item{u}{(default: \code{NULL}) a matrix of rank values (with sample as
+column)}
 
 \item{estimate}{the results of \code{fit_mixture(u)}}
 
diff --git a/man/fit_mixture.Rd b/man/fit_mixture.Rd
index bee06f0..41a8629 100644
--- a/man/fit_mixture.Rd
+++ b/man/fit_mixture.Rd
@@ -42,6 +42,8 @@ between the rank and the rank + 1}
 \item{method}{(default: \code{"arch"}), use the samic or originial gaussian model \code{c("arch", "gaussian", "emp")}}
 
 \item{two_step}{(default: \code{F}) **experimental** alternative fitting procedure}
+
+\item{estimate}{list of parameters values}
 }
 \value{
 a \code{fitCopula} object of the \code{copula} package
diff --git a/man/gatherpairs.Rd b/man/gatherpairs.Rd
index 8bc3a1b..21c410f 100644
--- a/man/gatherpairs.Rd
+++ b/man/gatherpairs.Rd
@@ -26,9 +26,9 @@ gatherpairs(
 
 \item{xvalue}{name of the column for x values}
 
-\item{ykey}{name of the column for x names}
+\item{ykey}{name of the column for x names @param yvalue name of the column for x values}
 
-\item{yvalue}{name of the column for x values}
+\item{yvalue}{name of the column for y values}
 
 \item{na.rm}{(default: \code{FALSE}) should \code{NA} values be removed}
 
diff --git a/man/idr.Rd b/man/idr.Rd
new file mode 100644
index 0000000..12c112a
--- /dev/null
+++ b/man/idr.Rd
@@ -0,0 +1,45 @@
+% Generated by roxygen2: do not edit by hand
+% Please edit documentation in R/main.R
+\name{idr}
+\alias{idr}
+\title{Compte the IDR}
+\usage{
+idr(
+  data = NULL,
+  estimate = NULL,
+  eps = 0.001,
+  method = "arch",
+  type = "pseudo",
+  verbose = FALSE
+)
+}
+\arguments{
+\item{data}{(default: \code{NULL}) a matrix of data values (with sample as
+column)}
+
+\item{estimate}{the results of \code{pseudo_likelihood_fit_mixture(data)}}
+
+\item{eps}{(default: \code{1e-3}), threshold of the precision of the
+optimisation}
+
+\item{method}{(default: \code{"arch"}), use the samic or originial gaussian
+model \code{c("arch", "gaussian", "emp")}}
+
+\item{type}{(default: \code{"pseudo"}), perform classical IDR computation or
+computation without the hypothesis that lower score are less reproducible
+(for testing only) \code{c("pseudo", "direct")}}
+
+\item{verbose}{(default: \code{F}) print messages}
+}
+\value{
+a list of a vector of idr values of size \code{nrow(u)} and a list
+of estimate values
+}
+\description{
+Compte the IDR
+}
+\examples{
+\dontrun{
+idr(data)
+}
+}
diff --git a/man/mono_fit_mixture.Rd b/man/mono_fit_mixture.Rd
index f1ce9c7..9583307 100644
--- a/man/mono_fit_mixture.Rd
+++ b/man/mono_fit_mixture.Rd
@@ -27,6 +27,8 @@ mono_fit_mixture(
 
 \item{method}{(default: \code{"arch"}), use the samic or originial gaussian model \code{c("arch", "gaussian", "emp")}}
 
+\item{estimate}{the results of \code{pseudo_likelihood_fit_mixture(data)}}
+
 \item{init}{(default: \code{c(copula_mixture_theta(samic), copula_mixture_weight(samic))}), starting set of parameters}
 }
 \value{
diff --git a/man/mono_fit_mixture_arch.Rd b/man/mono_fit_mixture_arch.Rd
index ced8ee3..54bd5f5 100644
--- a/man/mono_fit_mixture_arch.Rd
+++ b/man/mono_fit_mixture_arch.Rd
@@ -28,11 +28,11 @@ mono_fit_mixture_arch(
 
 \item{estimate}{a vector or mode parameters}
 
+\item{optim_method}{(default: \code{mpl}) the fitting method}
+
 \item{prop}{(default: \code{1.}) faction of the data to use for estimation}
 
 \item{method}{(default: \code{"arch"}), use the samic or originial gaussian model \code{c("arch", "gaussian", "emp")}}
-
-\item{optim}{method (default: \code{mpl}) the fitting method}
 }
 \value{
 a \code{fitCopula} object of the \code{copula} package
diff --git a/man/prod_pseudo_copula_mixture.Rd b/man/prod_pseudo_copula_mixture.Rd
index 6d3b11e..83863ae 100644
--- a/man/prod_pseudo_copula_mixture.Rd
+++ b/man/prod_pseudo_copula_mixture.Rd
@@ -18,7 +18,7 @@ copula weight}
 
 \item{u}{a matrix of pseudo-rank}
 
-\item{method}{(default: \code{"arch"}), use the samic or originial gaussian model}
+\item{fn_method}{(default: \code{"arch"}), use the samic or originial gaussian model}
 }
 \value{
 the log-likelihood of the copula mixture model given the data
diff --git a/man/prod_pseudo_marginal.Rd b/man/prod_pseudo_marginal.Rd
index d5d9e00..cd8c15c 100644
--- a/man/prod_pseudo_marginal.Rd
+++ b/man/prod_pseudo_marginal.Rd
@@ -7,6 +7,8 @@
 prod_pseudo_marginal(u, params, estimate, K, z, fn_method = "arch")
 }
 \arguments{
+\item{u}{(default: \code{NULL}) a matrix of rank values (with sample as column)}
+
 \item{params}{a named vector of variables model parameters}
 
 \item{estimate}{a named vector of all the model parameters}
@@ -15,7 +17,7 @@ prod_pseudo_marginal(u, params, estimate, K, z, fn_method = "arch")
 
 \item{z}{a matrix of pseudo-values}
 
-\item{method}{(default: \code{"arch"}), use the samic or originial gaussian model}
+\item{fn_method}{(default: \code{"arch"}), use the samic or originial gaussian model}
 }
 \value{
 the log-likelihood of the marginal mixture model given the data
diff --git a/man/pseudo_compute_idr.Rd b/man/pseudo_compute_idr.Rd
index 3a671e5..b891de5 100644
--- a/man/pseudo_compute_idr.Rd
+++ b/man/pseudo_compute_idr.Rd
@@ -22,8 +22,6 @@ pseudo_compute_idr(
 \item{method}{(default: \code{"arch"}), use the samic or originial gaussian model \code{c("arch", "gaussian", "emp")}}
 
 \item{verbose}{(default: \code{F}) print messages}
-
-\item{u}{(default: \code{NULL}) a matrix of rank values (with sample as column)}
 }
 \value{
 a list of a vector of idr values of size \code{nrow(u)} and a list of estimate values
diff --git a/man/pseudo_copula_mixture.Rd b/man/pseudo_copula_mixture.Rd
index c4cafcb..f303099 100644
--- a/man/pseudo_copula_mixture.Rd
+++ b/man/pseudo_copula_mixture.Rd
@@ -13,6 +13,8 @@ pseudo_copula_mixture(
 )
 }
 \arguments{
+\item{u}{(default: \code{NULL}) a matrix of rank values (with sample as column)}
+
 \item{theta}{(defaut: \code{copula_mixture_theta()} a named vector of theta
 values as generated by the \code{copula_mixture_theta()} function}
 
diff --git a/man/pseudo_fit_marginal.Rd b/man/pseudo_fit_marginal.Rd
index d0cb7a2..abfaa9b 100644
--- a/man/pseudo_fit_marginal.Rd
+++ b/man/pseudo_fit_marginal.Rd
@@ -18,6 +18,8 @@ pseudo_fit_marginal(
 \arguments{
 \item{z}{a matrix of pseudo-values}
 
+\item{u}{(default: \code{NULL}) a matrix of rank values (with sample as column)}
+
 \item{K}{a vector of indep probability of size \code{ncol(z)}}
 
 \item{L}{for \code{samic = T} a matrix of size \code{ncol(z) * 3} for archimean
diff --git a/man/pseudo_likelihood_fit_mixture.Rd b/man/pseudo_likelihood_fit_mixture.Rd
index e74ec90..77d4849 100644
--- a/man/pseudo_likelihood_fit_mixture.Rd
+++ b/man/pseudo_likelihood_fit_mixture.Rd
@@ -24,6 +24,10 @@ pseudo_likelihood_fit_mixture(
 \item{method}{(default: \code{"arch"}) use the samic or originial gaussian model}
 
 \item{eps}{(default: \code{1e-3}), threshold of the precision of the optimisation}
+
+\item{fixed_estimate}{the results of \code{pseudo_likelihood_fit_mixture(data)}}
+
+\item{verbose}{(default: \code{F}) print messages}
 }
 \value{
 a \code{fitCopula} object of the \code{copula} package
diff --git a/man/pseudo_local_idr.Rd b/man/pseudo_local_idr.Rd
index c469815..ecb95b6 100644
--- a/man/pseudo_local_idr.Rd
+++ b/man/pseudo_local_idr.Rd
@@ -12,6 +12,8 @@ pseudo_local_idr(u = NULL, estimate = NULL, method = "arch", verbose = F)
 \item{estimate}{the results of \code{fit_mixture(u)}}
 
 \item{method}{(default: \code{"arch"}), use the samic or originial gaussian model}
+
+\item{verbose}{(default: \code{F}) print messages}
 }
 \value{
 a vector of idr values of size \code{nrow(u)}
diff --git a/man/pseudo_rename_params.Rd b/man/pseudo_rename_params.Rd
index 69bbed4..de2104e 100644
--- a/man/pseudo_rename_params.Rd
+++ b/man/pseudo_rename_params.Rd
@@ -9,6 +9,8 @@ for the models from a unnamed vectors}
 pseudo_rename_params(params, method = "arch")
 }
 \arguments{
+\item{params}{named vector of model parameters}
+
 \item{method}{(default: \code{"arch"}), use the samic or originial gaussian model}
 }
 \value{
diff --git a/man/pseudo_rename_theta.Rd b/man/pseudo_rename_theta.Rd
index 655f530..9fe3161 100644
--- a/man/pseudo_rename_theta.Rd
+++ b/man/pseudo_rename_theta.Rd
@@ -9,6 +9,8 @@ for the models from a unnamed vectors}
 pseudo_rename_theta(theta, method = "arch")
 }
 \arguments{
+\item{theta}{named vector of theta values}
+
 \item{method}{(default: \code{"arch"}), use the samic or originial gaussian model}
 }
 \value{
diff --git a/man/pseudo_rename_weight.Rd b/man/pseudo_rename_weight.Rd
index 7447fcb..a0974ad 100644
--- a/man/pseudo_rename_weight.Rd
+++ b/man/pseudo_rename_weight.Rd
@@ -9,6 +9,8 @@ for the models from a unnamed vectors}
 pseudo_rename_weight(weight, method = "arche")
 }
 \arguments{
+\item{weight}{named vector of weight values}
+
 \item{method}{(default: \code{"arch"}), use the samic or originial gaussian model}
 }
 \value{
-- 
GitLab