% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/msqrob-utils.R
\name{createPairwiseContrasts}
\alias{createPairwiseContrasts}
\title{Construct all contrasts for all pairwise comparisons between all levels of a factor}
\usage{
createPairwiseContrasts(
  formula,
  coldata,
  var,
  ridge = FALSE,
  nullHypothesis = " = 0"
)
}
\arguments{
\item{formula}{Model formula. The model is built based on the covariates in the 'coldata' object.}

\item{coldata}{data.frame or DFrame with information on the design.}

\item{var}{object of type 'character' with the name of the factor in the formula for which the
pairwise comparisons will be made.}

\item{ridge}{logical indicating if the msqrob models are fitted with or without ridge regression.
The default is 'ridge = FALSE'}

\item{nullHypothesis}{object of type character that specifies the value of the contrast under the null
hypothesis. The default is ' = 0'.}
}
\value{
Vector of type character with nulhypotheses for all contrasts.
}
\description{
Construct all contrasts for all pairwise comparisons between all levels of a factor.
}
\examples{
# Load example data
# The data are a Feature object containing
# a SummarizedExperiment named "peptide" with MaxQuant peptide intensities
# The data are a subset of spike-in the human-ecoli study
# The variable condition in the colData of the Feature object
# contains information on the spike in condition a-e (from low to high)
data(pe)

# Model with intercept (conditiona is reference class)
createPairwiseContrasts(~ condition, colData(pe), "condition")

# Model without intercept
createPairwiseContrasts(~ -1 + condition, colData(pe), "condition")

}
