setPriorDfVarRatio {MAnorm2}R Documentation

Set the Number of Prior Degrees of Freedom and Variance Ratio Factors

Description

Given a set of bioCond objects of which each has been associated with a mean-variance curve, setPriorDfVarRatio assigns a common number of prior degrees of freedom to all of them and sets their variance ratio factors based on user-provided values. There are few scenarios where you need to call this function (see "Details").

Usage

setPriorDfVarRatio(
  conds,
  d0 = 0,
  ratio.var = estimateVarRatio(conds),
  .call = TRUE
)

Arguments

conds

A list of bioCond objects, of which each has a fit.info field describing its mean-variance curve (see also fitMeanVarCurve).

d0

A non-negative real specifying the number of prior degrees of freedom. Specifying a value other than 0 will lead to a warning (see also "Details").

ratio.var

A vector giving the variance ratio factors of the bioConds. Elements are recycled if necessary. By default, it's estimated by calling estimateVarRatio.

.call

Never care about this argument.

Details

Basically, the only reason for which you need to call this function is that you don't want to borrow information between genomic intervals to improve variance estimation. Therefore, this function should be in principle called always with the default value (i.e., 0) for d0, in which case you can still account for potential differences in global within-group variability between groups of samples. Otherwise, you should empirically estimate d0 via, for example, estimatePriorDf or estimatePriorDfRobust.

There are two typical scenarios in which you don't want to borrow information between genomic intervals. In the first one, the estimated d0 derived by estimatePriorDfRobust is 0 because the underlying variance structure is highly irregular. In the second one, there are sufficient replicate samples (e.g., >7 profiles in each group) such that observed variances alone could provide reliable variance estimates.

Value

The argument list of bioCond objects, with updated "df.prior" and "ratio.var" components.

See Also

bioCond for creating a bioCond object; fitMeanVarCurve for fitting a mean-variance curve and using a fit.info field to characterize it; estimatePriorDf and estimatePriorDfRobust for estimating the number of prior degrees of freedom and adjusting the variance ratio factors of a set of bioConds; setPriorDf and setPriorDfRobust for setting the number of prior degrees of freedom and accordingly adjusting the variance ratio factors of a set of bioConds.


[Package MAnorm2 version 1.2.2 Index]