diff --git a/DESCRIPTION b/DESCRIPTION index 1fdc4cd..a8da22e 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: msDiaLogue Title: Analysis + Visuals for Data Indep. Aquisition Mass Spectrometry Data -Version: 0.0.4 +Version: 0.0.5 Authors@R: c( person("Shiying", "Xiao", email = "shiying.xiao@uconn.edu", role = c("aut", "cre"), comment = c(ORCID = "0000-0002-8846-3258")), diff --git a/R/analyze.R b/R/analyze.R index bf4dfaa..f077eb9 100644 --- a/R/analyze.R +++ b/R/analyze.R @@ -11,7 +11,7 @@ ## version (at your option). See the GNU General Public License at ## for details. ## -## The R package wdnet is distributed in the hope that it will be useful, +## The R package msDiaLogue is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ## @@ -27,14 +27,27 @@ #' #' @param dataSet The 2d data set of data. #' -#' @param conditions A string specifying which two conditions to compare. This argument -#' only works when there are more than two conditions in \code{dataSet}. +#' @param conditions A string specifying which two conditions to compare. The order is +#' important, as the second condition serves as the reference for comparison. When there +#' are two conditions in \code{dataSet} and this argument is not specified, the +#' \code{conditions} will automatically be selected by sorting the unique values +#' alphabetically and in ascending order. #' #' @param testType A string (default = "t-test") specifying which statistical test to use: #' \enumerate{ -#' \item "t-test": unequal variance t-test. -#' \item "mod.t-test": moderated t-test \insertCite{smyth2004linear}{msDiaLogue}. -#' \item "MA": output to plot an MA plot. +#' \item "t-test": Unequal variance t-test. +#' \item "mod.t-test": Moderated t-test \insertCite{smyth2004linear}{msDiaLogue}. +#' \item "MA": Output to plot an MA plot. +#' } +#' +#' @details +#' The second condition serves as the reference for comparison. \itemize{ +#' \item "t-test" and "mod.t-test": The differences are calculated by subtracting +#' the mean of the second condition from the mean of the first condition (Condition 1 - +#' Condition 2). +#' \item "MA": The rows are ordered by \code{conditions}. Specifically, the first row +#' corresponds to the protein-wise average of the first condition, and the second row +#' corresponds to the second condition. #' } #' #' @import dplyr @@ -45,9 +58,7 @@ #' #' @returns A 2d dataframe includes the following information: \itemize{ #' \item "t-test" or "mod.t-test": The differences in means and P-values for each protein -#' between the two conditions. Note that the differences are calculated by subtracting the -#' mean of the second condition from the mean of the first condition (Condition 1 - -#' Condition 2). +#' between the two conditions. #' \item "MA": Protein-wise averages within each condition. #' } #' @@ -62,7 +73,7 @@ analyze <- function(dataSet, conditions, testType = "t-test") { ## check for exactly two conditions if (missing(conditions)) { - conditions <- unique(dataSet$R.Condition) + conditions <- sort(unique(dataSet$R.Condition)) if (length(conditions) != 2) { stop("Please provide exactly two conditions for comparison.") } diff --git a/R/dataMissing.R b/R/dataMissing.R index feef481..95a1475 100644 --- a/R/dataMissing.R +++ b/R/dataMissing.R @@ -11,7 +11,7 @@ ## version (at your option). See the GNU General Public License at ## for details. ## -## The R package wdnet is distributed in the hope that it will be useful, +## The R package msDiaLogue is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ## diff --git a/R/filterings.R b/R/filterings.R index 6c2c8b3..4b77c03 100644 --- a/R/filterings.R +++ b/R/filterings.R @@ -11,7 +11,7 @@ ## version (at your option). See the GNU General Public License at ## for details. ## -## The R package wdnet is distributed in the hope that it will be useful, +## The R package msDiaLogue is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ## diff --git a/R/imputations.R b/R/imputations.R index 6dff89b..0e3e969 100644 --- a/R/imputations.R +++ b/R/imputations.R @@ -11,7 +11,7 @@ ## version (at your option). See the GNU General Public License at ## for details. ## -## The R package wdnet is distributed in the hope that it will be useful, +## The R package msDiaLogue is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ## diff --git a/R/normalize.R b/R/normalize.R index 45853d8..4947c94 100644 --- a/R/normalize.R +++ b/R/normalize.R @@ -6,6 +6,16 @@ ## This file is part of the R package msDiaLogue. ## ## The R package msDiaLogue is free software: You can redistribute it and/or +## modify it under the terms of the GNU General Public License as published by +## the Free Software Foundation, either version 3 of the License, or any later +## version (at your option). See the GNU General Public License at +## for details. +## +## The R package msDiaLogue is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +## + ################################### #### Code for data normalizing #### ################################### diff --git a/R/preprocessing.R b/R/preprocessing.R index dff22e3..c5c53ec 100644 --- a/R/preprocessing.R +++ b/R/preprocessing.R @@ -11,7 +11,7 @@ ## version (at your option). See the GNU General Public License at ## for details. ## -## The R package wdnet is distributed in the hope that it will be useful, +## The R package msDiaLogue is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ## diff --git a/R/pullProteinPath.R b/R/pullProteinPath.R index bea68c5..6aaeb25 100644 --- a/R/pullProteinPath.R +++ b/R/pullProteinPath.R @@ -11,7 +11,7 @@ ## version (at your option). See the GNU General Public License at ## for details. ## -## The R package wdnet is distributed in the hope that it will be useful, +## The R package msDiaLogue is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ## diff --git a/R/sortcondition.R b/R/sortcondition.R index fcceb4e..3cfbdb8 100644 --- a/R/sortcondition.R +++ b/R/sortcondition.R @@ -4,6 +4,18 @@ ## Shiying Xiao ## ## This file is part of the R package msDiaLogue. +## +## The R package msDiaLogue is free software: You can redistribute it and/or +## modify it under the terms of the GNU General Public License as published by +## the Free Software Foundation, either version 3 of the License, or any later +## version (at your option). See the GNU General Public License at +## for details. +## +## The R package msDiaLogue is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +## + #' Creating a keyed list of conditions to the list of proteins that are present #' #' @description diff --git a/R/summarize.R b/R/summarize.R index fbb6dd7..16f1845 100644 --- a/R/summarize.R +++ b/R/summarize.R @@ -11,7 +11,7 @@ ## version (at your option). See the GNU General Public License at ## for details. ## -## The R package wdnet is distributed in the hope that it will be useful, +## The R package msDiaLogue is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ## @@ -34,18 +34,18 @@ #' @details #' The column 'Stat' in the generated data.frame includes the following statistics: #' \itemize{ -#' \item n: number. -#' \item mean: mean. -#' \item sd: standard deviation. -#' \item median: median. -#' \item trimmed: trimmed mean with a trim of 0.1. -#' \item mad: median absolute deviation (from the median). -#' \item min: minimum. -#' \item max: maximum. -#' \item range: the difference between the maximum and minimum value. -#' \item skew: skewness. -#' \item kurtosis: kurtosis. -#' \item se: standard error. +#' \item n: Number. +#' \item mean: Mean. +#' \item sd: Standard deviation. +#' \item median: Median. +#' \item trimmed: Trimmed mean with a trim of 0.1. +#' \item mad: Median absolute deviation (from the median). +#' \item min: Minimum. +#' \item max: Maximum. +#' \item range: The difference between the maximum and minimum value. +#' \item skew: Skewness. +#' \item kurtosis: Kurtosis. +#' \item se: Standard error. #' } #' #' @import dplyr diff --git a/R/transform.R b/R/transform.R index 27a6b0c..1164b55 100644 --- a/R/transform.R +++ b/R/transform.R @@ -11,7 +11,7 @@ ## version (at your option). See the GNU General Public License at ## for details. ## -## The R package wdnet is distributed in the hope that it will be useful, +## The R package msDiaLogue is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ## diff --git a/R/trimFASTA.R b/R/trimFASTA.R index 0a2203b..ec104b2 100644 --- a/R/trimFASTA.R +++ b/R/trimFASTA.R @@ -11,7 +11,7 @@ ## version (at your option). See the GNU General Public License at ## for details. ## -## The R package wdnet is distributed in the hope that it will be useful, +## The R package msDiaLogue is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ## diff --git a/R/trunc-knn.R b/R/trunc-knn.R index 8432b57..0468c3d 100644 --- a/R/trunc-knn.R +++ b/R/trunc-knn.R @@ -11,7 +11,7 @@ ## version (at your option). See the GNU General Public License at ## for details. ## -## The R package wdnet is distributed in the hope that it will be useful, +## The R package msDiaLogue is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ## diff --git a/R/visualizations.R b/R/visualizations.R index 208f3d7..060c07a 100644 --- a/R/visualizations.R +++ b/R/visualizations.R @@ -11,7 +11,7 @@ ## version (at your option). See the GNU General Public License at ## for details. ## -## The R package wdnet is distributed in the hope that it will be useful, +## The R package msDiaLogue is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ## @@ -107,10 +107,10 @@ #' @param label A text (default = "all") specifying the elements to be labelled when #' \code{graphType = "PCA_biplot"}. Allowed values: #' \itemize{ -#' \item "all": label both active individuals and active variables. -#' \item "ind": label only active individuals. -#' \item "var": label only active variables. -#' \item "none": no labels. +#' \item "all": Label both active individuals and active variables. +#' \item "ind": Label only active individuals. +#' \item "var": Label only active variables. +#' \item "none": No labels. #' } #' #' @param show_percentage A boolean (default = TRUE) specifying whether to show the diff --git a/docs/404.html b/docs/404.html index 9939d57..a39c06a 100644 --- a/docs/404.html +++ b/docs/404.html @@ -26,7 +26,7 @@ msDiaLogue - 0.0.4 + 0.0.5