Allows for the computation of differential analyses using prolfqua (J Proteome Research, 2023). Includes means, Fold Changes, and p-values.

# S3 method for class 'analyses.prolfqua'
diff(
  DEprot.object,
  contrast.list,
  linear.FC.th = 2,
  linear.FC.unresp.range = c(1/1.1, 1.1),
  FDR.th = 0.05,
  strategy = "lm",
  moderate.variance = FALSE,
  up.color = "indianred",
  down.color = "steelblue",
  unresponsive.color = "purple",
  null.color = "gray",
  which.data = "imputed",
  overwrite.analyses = FALSE
)

Arguments

DEprot.object

An object of class DEprot.

contrast.list

List of 3-elements vectors indicating (in order): metadata_column, variable_1, variable_2.

linear.FC.th

Number indicating the (absolute) fold change threshold (linear scale) to use to define differential proteins. Default: 2.

linear.FC.unresp.range

A numeric 2-elements vector indicating the range (linear scale) used to define the unresponsive fold changes. Default: c(1/1.1, 1.1).

FDR.th

Numeric value indicating the FDR threshold to apply to the differential analyses. Default: 0.05.

strategy

String indicating the method that prolfqua should use to fit the model. One among: "lm" (linear model, default), "glm" (general lm), "lmer" (linear mixed-effects model), "logistf" (Firth's bias-reduced logistic regression), "rlm" (robust lm). Default: "lm" (linear model).

moderate.variance

String indicating whether the variance should be moderated in the evaluation of the contrast. Default: FALSE.

up.color

String indicating the color to use for up-regulated proteins in the plots. Default: "indianred".

down.color

String indicating the color to use for up-regulated proteins in the plots. Default: "steelblue".

unresponsive.color

String indicating the color to use for unresponsive proteins in the plots. Default: "purple".

null.color

String indicating the color to use for null proteins in the plots. Default: "gray".

which.data

String indicating which type of counts should be used. One among: 'raw', 'normalized', 'norm', 'imputed', 'imp'. Default: "imputed".

overwrite.analyses

Logical value to indicate whether overwrite analyses already generated. Default: FALSE.

Value

An object of class DEprot.analyses

Author

Sebastian Gregoricchio

Examples

dpo <- diff.analyses.prolfqua(DEprot.object = DEprot::test.toolbox$dpo.imp,
                              contrast.list = list(c("condition", "FBS", "6h.DMSO"),
                                                   c("condition", "6h.10nM.E2", "6h.DMSO")),
                              strategy = "lm",
                              linear.FC.th = 1.2)