Description Usage Arguments Details Value Author(s) References See Also Examples

Estimate relative quality weights for each array or group in a multi-array experiment.

1 2 3 |

`object` |
any matrix-like object containing log-expression values or log-ratio expression values, for example an |

`design` |
the design matrix of the microarray experiment, with rows corresponding to arrays and columns to coefficients to be estimated. Defaults to the unit vector meaning that the arrays are treated as replicates. |

`weights` |
numeric matrix containing prior weights for each expresson value. |

`var.design` |
design matrix for the variance model. Defaults to the sample-specific model whereby each sample has a distinct variance. |

`var.group` |
vector or factor indicating groups to have different array weights. This is another way to specify |

`prior.n` |
prior number of genes. Larger values squeeze the array weights more strongly towards equality. |

`method` |
character string specifying the estimating algorithm to be used. Choices
are |

`maxiter` |
maximum number of iterations allowed when |

`tol` |
convergence tolerance when |

`trace` |
logical. If |

The relative reliability of each array is estimated by measuring how well the expression values for that array follow the linear model. Arrays that tend to have larger residuals are assigned lower weights.

The basic method is described by Ritchie et al (2006) and the extension to custom variance models by Liu et al (2015).
A weighted linear model is fitted to the expression values for
each gene.
The variance model is fitted to the squared residuals from the linear model fit and is updated either by full REML
scoring iterations (`method="reml"`

) or using an efficient gene-by-gene update algorithm (`method="genebygene"`

).
The final estimates of these array variances are converted to weights.
The gene-by-gene algorithm is described by Ritchie et al (2006) while the REML algorithm is an adaption of the algorithm of Smyth (2002).

For stability, the array weights are squeezed slightly towards equality.
This is done by adding a prior likelihood corresponding to unit array weights equivalent to `prior.n`

genes.
The gene-by-gene algorithm is started from the prior genes while the REML algorithm adds the prior to the log-likelihood derivatives.

By default, `arrayWeights`

chooses between the REML and gene-by-gene algorithms automatically (`method="auto"`

).
REML is chosen if there are no prior weights or missing values and otherwise the gene-by-gene algorithm is used.

The input `object`

is interpreted as for `lmFit`

and `getEAWP`

.
In particular, the arguments `design`

and `weights`

will be extracted from the data
`object`

if available and do not normally need to be set explicitly in
the call; if any of these are set in the call then they will over-ride
the slots or components in the data `object`

.

A numeric vector of array weights, which multiply to 1.

Matthew Ritchie and Gordon Smyth

Liu, R., Holik, A. Z., Su, S., Jansz, N., Chen, K., Leong, H. S., Blewitt, M. E., Asselin-Labat, M.-L., Smyth, G. K., Ritchie, M. E. (2015).
Why weight? Combining voom with estimates of sample quality improves power in RNA-seq analyses.
*Nucleic Acids Research* 43, e97.
http://nar.oxfordjournals.org/content/43/15/e97

Ritchie, M. E., Diyagama, D., Neilson, van Laar, R., J., Dobrovic, A., Holloway, A., and Smyth, G. K. (2006).
Empirical array quality weights in the analysis of microarray data.
*BMC Bioinformatics* **7**, 261.
http://www.biomedcentral.com/1471-2105/7/261

Smyth, G. K. (2002).
An efficient algorithm for REML in heteroscedastic regression.
*Journal of Computational and Graphical Statistics* **11**, 836-847.
http://www.statsci.org/smyth/pubs/remlalgo.pdf

`arrayWeightsQuick`

, `voomWithQualityWeights`

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

1 2 3 4 5 6 |

```
1 2 3 4 5 6
0.5016262 0.5016262 0.5016262 1.9935163 1.9935163 1.9935163
```

limma documentation built on Nov. 8, 2020, 8:28 p.m.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.