makeContrasts {limma} | R Documentation

## Construct Matrix of Custom Contrasts

### Description

Construct the contrasts matrix corresponding to specified contrasts of a set of given parameters.

### Usage

    makeContrasts(..., levels)

### Arguments

`...` | expressions, or character strings which can be parsed to expressions, specifying contrasts
`levels` | character vector giving the names of the parameters to be contrasts, or a factor or design matrix from which the names can be extracted.

### Value

Matrix which columns corresponding to contrasts.

### Author(s)

Gordon Smyth

### See Also

An overview of linear model functions in limma is given by 06.LinearModels.

### Examples

    makeContrasts(B-A,C-B,C-A,levels=c("A","B","C"))
    makeContrasts("A","B","B-A",levels=c("A","B"))

[Package limma version 2.6.2 Index]