Skip to content

Commit

Permalink
Merge pull request #99 from adrientaudiere/dev
Browse files Browse the repository at this point in the history
test: Change value in test for different version of vsearch
  • Loading branch information
adrientaudiere authored Sep 5, 2024
2 parents 354461f + 24c917c commit 76a25f8
Show file tree
Hide file tree
Showing 98 changed files with 192 additions and 177 deletions.
10 changes: 5 additions & 5 deletions R/Deseq2_edgeR.R
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
#' }
#' @author Adrien Taudière
#'
#' @return A \code{\link{ggplot}}2 plot representing edgeR results
#' @return A \code{\link[ggplot2]{ggplot}}2 plot representing edgeR results
#'
#' @seealso \code{\link[edgeR]{exactTest}}
#' @seealso \code{\link{plot_deseq2_pq}}
Expand Down Expand Up @@ -133,12 +133,12 @@ plot_edgeR_pq <-
#'
#' Graphical representation of DESeq2 analysis.
#'
#' @param data (required) a \code{\link{phyloseq-class}} or a
#' @param data (required) a \code{\link[phyloseq]{phyloseq-class}} or a
#' \code{\link[DESeq2]{DESeqDataSet-class}} object.
#' @param tax_table Required if data is a
#' \code{\link[DESeq2]{DESeqDataSet-class}} object.
#' The taxonomic table used to find the \code{taxa} and \code{color_taxa}
#' arguments. If data is a \code{\link{phyloseq-class}} object, data@tax_table
#' arguments. If data is a \code{\link[phyloseq]{phyloseq-class}} object, data@tax_table
#' is used.
#' @param contrast (required) contrast specifies what comparison to extract
#' from the object to build a results table. See \code{\link[DESeq2]{results}}
Expand All @@ -155,7 +155,7 @@ plot_edgeR_pq <-
#' @param tax_depth Taxonomic depth to test for differential
#' distribution among contrast. If Null the analysis is done at the OTU
#' (i.e. Species) level. If not Null, data need to be a column name in
#' the `tax_table` slot of the \code{\link{phyloseq-class}} object.
#' the `tax_table` slot of the \code{\link[phyloseq]{phyloseq-class}} object.
#' @param verbose whether the function print some information during
#' the computation
#' @param jitter_width width for the jitter positioning
Expand Down Expand Up @@ -190,7 +190,7 @@ plot_edgeR_pq <-
#' }
#' @author Adrien Taudière
#'
#' @return A \code{\link{ggplot}}2 plot representing DESeq2 results
#' @return A \code{\link[ggplot2]{ggplot}}2 plot representing DESeq2 results
#'
#' @seealso \code{\link[DESeq2]{DESeq}}
#' @seealso \code{\link[DESeq2]{results}}
Expand Down
2 changes: 1 addition & 1 deletion R/beta_div_test.R
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
#' }
#' @author Adrien Taudière
#'
#' @return A \code{\link{ggplot}}2 plot with a subtitle indicating the pvalue
#' @return A \code{\link[ggplot2]{ggplot}}2 plot with a subtitle indicating the pvalue
#' and the number of permutations
#' @details
#' This function is mainly a wrapper of the work of others.
Expand Down
10 changes: 5 additions & 5 deletions R/blast.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
################################################################################
#' Blast some sequence against `refseq` slot of a \code{\link{phyloseq-class}}
#' Blast some sequence against `refseq` slot of a \code{\link[phyloseq]{phyloseq-class}}
#' object.
#'
#' @description
Expand All @@ -9,7 +9,7 @@
#'
#' Use the blast software.
#'
#' @param physeq (required): a \code{\link{phyloseq-class}} object obtained
#' @param physeq (required): a \code{\link[phyloseq]{phyloseq-class}} object obtained
#' using the `phyloseq` package.
#' @param seq2search (required) path to a fasta file defining the sequences
#' you want to blast against the taxa (ASV, OTU) sequences from the physeq object.
Expand Down Expand Up @@ -181,7 +181,7 @@ blast_to_phyloseq <- function(physeq,


################################################################################
#' Blast all sequence of `refseq` slot of a \code{\link{phyloseq-class}}
#' Blast all sequence of `refseq` slot of a \code{\link[phyloseq]{phyloseq-class}}
#' object against a custom database.
#'
#' @description
Expand Down Expand Up @@ -371,7 +371,7 @@ blast_pq <- function(physeq,
#' Note that params `unique_per_seq` must be lft to TRUE and `score_filter`
#' must be left to FALSE.
#' @export
#' @return A new \code{\link{phyloseq-class}} object.
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object.


filter_asv_blast <- function(physeq,
Expand Down Expand Up @@ -631,7 +631,7 @@ blast_to_derep <- function(derep,
#' @param fasta_for_db path to a fasta file to make the blast database
#' @param silent (logical) If true, no message are printing.
#' @param ... Other arguments passed on to [blast_pq()] function.
#' @return A new \code{\link{phyloseq-class}} object with more information in tax_table based on a
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object with more information in tax_table based on a
#' blast on a given database
#'
#' @export
Expand Down
2 changes: 1 addition & 1 deletion R/controls.R
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ dist_pos_control <- function(physeq, samples_names, method = "bray") {
#' 6. `mean`: the mean of the three firsts methods
#' @param min_diff_for_cutoff (int) argument for method `cutoff_diff`.
#' Required if method is `cutoff_diff`, `min`, `max` or `mean`
#' @return A new \code{\link{phyloseq-class}} object.
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object.
#' @export
#'
#' @examples
Expand Down
20 changes: 10 additions & 10 deletions R/dada_phyloseq.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ if (getRversion() >= "2.15.1") {
#' @inheritParams clean_pq
#' @param prefix_taxa_names (default "Taxa_"): the prefix of taxa names (eg. "ASV_" or "OTU_")
#'
#' @return A new \code{\link{phyloseq-class}} object with `refseq` slot and new
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object with `refseq` slot and new
#' taxa names
#' @export

Expand Down Expand Up @@ -45,7 +45,7 @@ add_dna_to_phyloseq <- function(physeq, prefix_taxa_names = "Taxa_") {
#' (i) taxa names in refseq, taxonomy table and otu_table and between
#' (ii) sample names in sam_data and otu_table.
#'
#' @param physeq (required): a \code{\link{phyloseq-class}} object obtained
#' @param physeq (required): a \code{\link[phyloseq]{phyloseq-class}} object obtained
#' using the `phyloseq` package.
#' @param remove_empty_samples (logical) Do you want to remove samples
#' without sequences (this is done after removing empty taxa)
Expand All @@ -68,7 +68,7 @@ add_dna_to_phyloseq <- function(physeq, prefix_taxa_names = "Taxa_") {
#' @param simplify_taxo (logical) if TRUE, correct the taxonomy_table using the
#' `MiscMetabar::simplify_taxo()` function
#' @param prefix_taxa_names (default "Taxa_"): the prefix of taxa names (eg. "ASV_" or "OTU_")
#' @return A new \code{\link{phyloseq-class}} object
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object
#' @export
clean_pq <- function(physeq,
remove_empty_samples = TRUE,
Expand Down Expand Up @@ -1605,7 +1605,7 @@ subset_taxa_pq <- function(physeq,
#' @inheritParams clean_pq
#' @param sam_name (required) The sample name to select
#' @param silent (logical) If true, no message are printing.
#' @return A new \code{\link{phyloseq-class}} object with one sample
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object with one sample
#'
#' @export
#'
Expand Down Expand Up @@ -1674,7 +1674,7 @@ select_one_sample <- function(physeq, sam_name, silent = FALSE) {
#' If set to NULL (the default), the basename of the file reFasta
#' is used.
#' @param ... Other arguments pass on to `dada2::assignTaxonomy`.
#' @return A new \code{\link{phyloseq-class}} object with a larger slot tax_table"
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object with a larger slot tax_table"
#'
#' @export
#'
Expand Down Expand Up @@ -1712,7 +1712,7 @@ add_new_taxonomy_pq <- function(physeq, ref_fasta, suffix = NULL, ...) {
#' informative columns (categorical column with one value per samples),
#' e.g. samples names ?
#' @param ... Other arguments pass on to [gtsummary::tbl_summary()].
#' @return A new \code{\link{phyloseq-class}} object with a larger slot tax_table
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object with a larger slot tax_table
#'
#' @export
#' @author Adrien Taudière
Expand Down Expand Up @@ -2615,7 +2615,7 @@ taxa_only_in_one_level <- function(physeq,
#' @param digits (default = 2) integer indicating the number of decimal places
#' to be used (see `?round` for more information)
#'
#' @return A new \code{\link{phyloseq-class}} object with otu_table count
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object with otu_table count
#' normalize and log transformed (if base_log is an integer)
#' @export
#' @author Adrien Taudière
Expand Down Expand Up @@ -2795,7 +2795,7 @@ psmelt_samples_pq <-
#' @inheritParams clean_pq
#' @author Adrien Taudière
#' @export
#' @return A new \code{\link{phyloseq-class}} object
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object
taxa_as_columns <- function(physeq) {
physeq <- clean_pq(
physeq,
Expand All @@ -2822,7 +2822,7 @@ taxa_as_columns <- function(physeq) {
#' @inheritParams clean_pq
#' @author Adrien Taudière
#' @export
#' @return A new \code{\link{phyloseq-class}} object
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object
taxa_as_rows <- function(physeq) {
physeq <- clean_pq(
physeq,
Expand Down Expand Up @@ -2858,7 +2858,7 @@ taxa_as_rows <- function(physeq) {
#' @param verbose (logical). If TRUE, print additional informations.
#' @export
#' @author Adrien Taudière
#' @return A new \code{\link{phyloseq-class}} object.
#' @return A new \code{\link[phyloseq]{phyloseq-class}} object.
#' @seealso [accu_plot_balanced_modality()]
#' @examples
#' table(data_fungi_mini@sam_data$Height)
Expand Down
6 changes: 3 additions & 3 deletions R/miscellanous.R
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
################################################################################
#' Transform the otu_table of a \code{\link{phyloseq-class}} object into a
#' \code{\link{phyloseq-class}} object with a binary otu_table.
#' Transform the otu_table of a \code{\link[phyloseq]{phyloseq-class}} object into a
#' \code{\link[phyloseq]{phyloseq-class}} object with a binary otu_table.
#'
#' @description
#'
Expand Down Expand Up @@ -131,7 +131,7 @@ all_object_size <- function() {
#' @param remove_space (logical; default TRUE): do we remove space?
#' @author Adrien Taudière
#'
#' @return A \code{\link{phyloseq-class}} object with simplified taxonomy
#' @return A \code{\link[phyloseq]{phyloseq-class}} object with simplified taxonomy
#' @export
simplify_taxo <- function(physeq, remove_space = TRUE) {
taxo <- physeq@tax_table
Expand Down
30 changes: 15 additions & 15 deletions R/plot_functions.R
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#' plot_mt(res)
#' plot_mt(res, taxa = "Genus", color_tax = "Order")
#' }
#' @return a \code{\link{ggplot}}2 plot of result of a mt test
#' @return a \code{\link[ggplot2]{ggplot}}2 plot of result of a mt test
#' @export
#' @seealso [phyloseq::mt()]

Expand Down Expand Up @@ -56,7 +56,7 @@ plot_mt <-


################################################################################
#' Plot accumulation curves for \code{\link{phyloseq-class}} object
#' Plot accumulation curves for \code{\link[phyloseq]{phyloseq-class}} object
#'
#' @description
#'
Expand Down Expand Up @@ -87,7 +87,7 @@ plot_mt <-
#' Only use if `add_nb_seq` = TRUE.
#' @param ci (default: 2, integer) Confidence interval value used to multiply the
#' standard error to plot confidence interval
#' @param ... Additional arguments passed on to \code{\link{ggplot}}
#' @param ... Additional arguments passed on to \code{\link[ggplot2]{ggplot}}
#' if `add_nb_seq` = TRUE or to \code{\link{plot}} if `add_nb_seq` = FALSE
#'
#' @examples
Expand All @@ -102,7 +102,7 @@ plot_mt <-
#'
#' p + xlim(c(0, 400))
#' }
#' @return A \code{\link{ggplot}}2 plot representing the richness
#' @return A \code{\link[ggplot2]{ggplot}}2 plot representing the richness
#' accumulation plot if add_nb_seq = TRUE, else, if add_nb_seq = FALSE
#' return a base plot.
#'
Expand Down Expand Up @@ -512,7 +512,7 @@ accu_samp_threshold <- function(res_accuplot, threshold = 0.95) {


################################################################################
#' Plot OTU circle for \code{\link{phyloseq-class}} object
#' Plot OTU circle for \code{\link[phyloseq]{phyloseq-class}} object
#' @description
#'
#' <a href="https://adrientaudiere.github.io/MiscMetabar/articles/Rules.html#lifecycle">
Expand Down Expand Up @@ -733,7 +733,7 @@ circle_pq <-
################################################################################

################################################################################
#' Sankey plot of \code{\link{phyloseq-class}} object
#' Sankey plot of \code{\link[phyloseq]{phyloseq-class}} object
#' @description
#'
#' <a href="https://adrientaudiere.github.io/MiscMetabar/articles/Rules.html#lifecycle">
Expand Down Expand Up @@ -956,7 +956,7 @@ sankey_pq <-
################################################################################

################################################################################
#' Venn diagram of \code{\link{phyloseq-class}} object
#' Venn diagram of \code{\link[phyloseq]{phyloseq-class}} object
#' @description
#'
#' <a href="https://adrientaudiere.github.io/MiscMetabar/articles/Rules.html#lifecycle">
Expand Down Expand Up @@ -992,7 +992,7 @@ sankey_pq <-
#' scale_fill_hue()
#' }
#' }
#' @return A \code{\link{ggplot}}2 plot representing Venn diagram of
#' @return A \code{\link[ggplot2]{ggplot}}2 plot representing Venn diagram of
#' modalities of the argument \code{factor}
#'
#' @export
Expand Down Expand Up @@ -1163,7 +1163,7 @@ venn_pq <-


################################################################################
#' Venn diagram of \code{\link{phyloseq-class}} object using
#' Venn diagram of \code{\link[phyloseq]{phyloseq-class}} object using
#' `ggVennDiagram::ggVennDiagram` function
#' @description
#'
Expand Down Expand Up @@ -1197,7 +1197,7 @@ venn_pq <-
#' modalities of args `fact`.
#' @param ... Other arguments for the `ggVennDiagram::ggVennDiagram` function
#' for ex. `category.names`.
#' @return A \code{\link{ggplot}}2 plot representing Venn diagram of
#' @return A \code{\link[ggplot2]{ggplot}}2 plot representing Venn diagram of
#' modalities of the argument \code{factor} or if split_by is set a list
#' of plots.
#' @seealso [upset_pq()]
Expand Down Expand Up @@ -1787,7 +1787,7 @@ ggbetween_pq <-


################################################################################
#' Summarize a \code{\link{phyloseq-class}} object using a plot.
#' Summarize a \code{\link[phyloseq]{phyloseq-class}} object using a plot.
#' @description
#'
#' <a href="https://adrientaudiere.github.io/MiscMetabar/articles/Rules.html#lifecycle">
Expand Down Expand Up @@ -3106,7 +3106,7 @@ iNEXT_pq <- function(physeq,
#' modalities of `fact` parameter
#' @param ... Other arguments passed on to the [ComplexUpset::upset()]
#'
#' @return A \code{\link{ggplot}}2 plot
#' @return A \code{\link[ggplot2]{ggplot}}2 plot
#' @export
#' @author Adrien Taudière
#'
Expand Down Expand Up @@ -3303,7 +3303,7 @@ upset_pq <- function(physeq,
#' the tax_table slot from the physeq object
#' @param ... Other arguments passed on to the [ComplexUpset::upset_test()]
#'
#' @return A \code{\link{ggplot}}2 plot
#' @return A \code{\link[ggplot2]{ggplot}}2 plot
#' @export
#' @author Adrien Taudière
#'
Expand Down Expand Up @@ -3516,7 +3516,7 @@ diff_fct_diff_class <-
#' @param nb_seq (logical; default TRUE) If set to FALSE, only the number of ASV
#' is count. Concretely, physeq otu_table is transformed in a binary
#' otu_table (each value different from zero is set to one)
#' @return A \code{\link{ggplot}}2 plot with bar representing the number of sequence en each
#' @return A \code{\link[ggplot2]{ggplot}}2 plot with bar representing the number of sequence en each
#' taxonomic groups
#' @export
#'
Expand Down Expand Up @@ -3579,7 +3579,7 @@ tax_bar_pq <-
#' @param tax_level The taxonomic level to fill ridges
#' @param ... Other params passed on to [ggridges::geom_density_ridges()]
#'
#' @return A \code{\link{ggplot}}2 plot with bar representing the number of sequence en each
#' @return A \code{\link[ggplot2]{ggplot}}2 plot with bar representing the number of sequence en each
#' taxonomic groups
#' @export
#' @author Adrien Taudière
Expand Down
2 changes: 1 addition & 1 deletion R/table_functions.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
################################################################################
#' Make a datatable with the taxonomy of a \code{\link{phyloseq-class}} object
#' Make a datatable with the taxonomy of a \code{\link[phyloseq]{phyloseq-class}} object
#'
#' @description
#'
Expand Down
22 changes: 18 additions & 4 deletions cran-comments.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,20 @@
Problem raised by CRAN Team the 22/08/2024 :
Resolved 2 Notes from CRAN submission

'Packages which use Internet resources should fail gracefully with an informative message
if the resource is not available or has changed (and not give a check warning nor error).'

Problem resolved in issue https://github.com/adrientaudiere/MiscMetabar/issues/97
# Invalid URLs

Found the following (possibly) invalid URLs:
URL: https://www.sciencedirect.com/science/article/abs/pii/S1754504815000847
From: man/add_funguild_info.Rd
man/get_funguild_db.Rd
Status: 403
Message: Forbidden

> I don't understand why the URL is invalid. It works for me.

# Bad \link{} for external packages

Found the following Rd file(s) with Rd \link{} targets missing package

> Solved in v. 0.9.3
2 changes: 1 addition & 1 deletion man/LCBD_pq.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/SRS_curve_pq.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 76a25f8

Please sign in to comment.