I'd like to use limma-voom to do a differential expression analysis on RNA-seq data using "my own" (i.e., external for limma) observation weights that downweigh outliers and which are different from voom weights. (I have a way to calculate the weights, that's not the issue). The user's guide and help files do not mention the possibility of using observation weights with voom; reading the code of lmFit, it seems to me that lmFit will disregard voom weights if I specify observation weights using argument weights. If this is not correct, please correct me.
If voom weights and the argument 'weights' indeed conflict in the lmFit function, assuming that the voom and my own weights are independent, can I simply multiply the 'weights' component of the output of voom with my own weights? (From reading voom code, a simple multiplication is used when sample weights are supplied, so hopefully this is not an outlandish proposition...)
Thanks in advance!
Thanks! If I may ask a second question, for designs without replicates (e.g., when there's a continuous covariate), is limma-voom a more appropriate option than edgeR or similar approaches that need dispersion estimation for each condition? Voom seems to use a single mean-variance function (for all genes and all conditions), so having no replicates would not seem to be a problem.
There is no problem at all with continuous covariates for either limma or edgeR. Either would be entirely appropriate.
You're jumping to some incorrect assumptions here. Having a continuous covariate is not the same as having no replicates and edgeR does not need to estimate a separate dispersion for each condition. Linear models (or generalized linear models in the case of edgeR) subsume all these possibilities elegantly without any difficulties.
If you really did not have replicates at all (meaning that the rank of the design matrix is equal to or greater than the number of samples) then you cannot use limma or edgeR in the normal way.
Thanks for the clarification.