Skip to content

Commit

Permalink
analyze: the texts regarding the reference; minor typo
Browse files Browse the repository at this point in the history
  • Loading branch information
Carol-seven committed Jul 7, 2024
1 parent 4537788 commit d342860
Show file tree
Hide file tree
Showing 54 changed files with 180 additions and 126 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -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 = "[email protected]",
role = c("aut", "cre"), comment = c(ORCID = "0000-0002-8846-3258")),
Expand Down
31 changes: 21 additions & 10 deletions R/analyze.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
## version (at your option). See the GNU General Public License at
## <https://www.gnu.org/licenses/> 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.
##
Expand All @@ -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
Expand All @@ -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.
#' }
#'
Expand All @@ -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.")
}
Expand Down
2 changes: 1 addition & 1 deletion R/dataMissing.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
## version (at your option). See the GNU General Public License at
## <https://www.gnu.org/licenses/> 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.
##
Expand Down
2 changes: 1 addition & 1 deletion R/filterings.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
## version (at your option). See the GNU General Public License at
## <https://www.gnu.org/licenses/> 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.
##
Expand Down
2 changes: 1 addition & 1 deletion R/imputations.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
## version (at your option). See the GNU General Public License at
## <https://www.gnu.org/licenses/> 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.
##
Expand Down
10 changes: 10 additions & 0 deletions R/normalize.R
Original file line number Diff line number Diff line change
Expand Up @@ -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
## <https://www.gnu.org/licenses/> 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 ####
###################################
Expand Down
2 changes: 1 addition & 1 deletion R/preprocessing.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
## version (at your option). See the GNU General Public License at
## <https://www.gnu.org/licenses/> 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.
##
Expand Down
2 changes: 1 addition & 1 deletion R/pullProteinPath.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
## version (at your option). See the GNU General Public License at
## <https://www.gnu.org/licenses/> 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.
##
Expand Down
12 changes: 12 additions & 0 deletions R/sortcondition.R
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,18 @@
## Shiying Xiao <[email protected]>
##
## 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
## <https://www.gnu.org/licenses/> 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
Expand Down
26 changes: 13 additions & 13 deletions R/summarize.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
## version (at your option). See the GNU General Public License at
## <https://www.gnu.org/licenses/> 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.
##
Expand All @@ -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
Expand Down
2 changes: 1 addition & 1 deletion R/transform.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
## version (at your option). See the GNU General Public License at
## <https://www.gnu.org/licenses/> 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.
##
Expand Down
2 changes: 1 addition & 1 deletion R/trimFASTA.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
## version (at your option). See the GNU General Public License at
## <https://www.gnu.org/licenses/> 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.
##
Expand Down
2 changes: 1 addition & 1 deletion R/trunc-knn.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
## version (at your option). See the GNU General Public License at
## <https://www.gnu.org/licenses/> 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.
##
Expand Down
10 changes: 5 additions & 5 deletions R/visualizations.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
## version (at your option). See the GNU General Public License at
## <https://www.gnu.org/licenses/> 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.
##
Expand Down Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion docs/404.html

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

2 changes: 1 addition & 1 deletion docs/LICENSE-text.html

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

2 changes: 1 addition & 1 deletion docs/articles/index.html

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

4 changes: 2 additions & 2 deletions docs/articles/scaffold.html

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

4 changes: 2 additions & 2 deletions docs/articles/usage_template.html

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

6 changes: 3 additions & 3 deletions docs/authors.html

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

2 changes: 1 addition & 1 deletion docs/index.html

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

2 changes: 1 addition & 1 deletion docs/pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ pkgdown_sha: ~
articles:
scaffold: scaffold.html
usage_template: usage_template.html
last_built: 2024-07-06T22:46Z
last_built: 2024-07-07T04:18Z
urls:
reference: https://uconn-scs.github.io/msDiaLogue/reference
article: https://uconn-scs.github.io/msDiaLogue/articles
Expand Down
Loading

0 comments on commit d342860

Please sign in to comment.