QSEA: choose appropriate reference for TMM normalisation with qsea::addLibraryFactors / qsea::estimateLibraryFactors
1
0
Entering edit mode
a.riediger ▴ 20
@f3a43e1e
Last seen 14 months ago
Germany

Hello everybody,

I aim to use the QSEA R package for the analysis of my MEDIP data. My question concerns the TMM normalisation which is applied by the function qsea::addLibraryFactors. Here, a reference can be either chosen manually or if e.g. ref=1 is set, then the first sample in the sampleTable is automatically chosen.

My data might show some variety, that's why I assume, I have to make a good choice for my reference sample. What are important criteria for the appropriate choice of a reference sample?

I had a look at the function edgeR::calcNormFactors, where there is the default option that "the library whose upper quartile is closest to the mean upper quartile for all the libraries" is chosen as the reference. I would prefer to use this option, as well, but struggle to integrate it into code for qsea::addLibraryFactors / qsea::estimateLibraryFactors.

Could somebody help me with this issue?

explaining the criteria to choose an appropriate reference sample or (even better) tell me how to integrate the code from edgeR::calcNormFactors into qsea:addLibraryFactors ?

Or do I get anything wrong and might don't have concern too much about the choice of the reference sample?

Thank you very much!

TMM edgeR qsea MEDIPS • 1.1k views
ADD COMMENT
0
Entering edit mode

Personally I have stopped using TMM normalisation in qsea, I don't think it is necessary provided you are removing poorly mapped windows correctly. As far as I'm aware, it is more important for RNAseq where you have ~30k genes and read counts spanning 4 orders of magnitude, than ~1M windows and 2 orders of magnitude (at least in my experience with MBD-Seq data). It doesn't make any difference for beta values, the scaling factors out for those.

ADD REPLY
1
Entering edit mode
@james-w-macdonald-5106
Last seen 15 hours ago
United States

The help page for addLibraryFactors says this:

Arguments:

      qs: The qseaSet object

 factors: In case normalization factors have been pre-computed by the
          user, they can be passed with this parameter.  In this case
          QSEA adds this factors to the qseaSet object and does not
          compute normalization factors.

Where the 'factors' argument clearly provides the opportunity to compute the TMM normalization factors yourself and then just add to the qseaSet object. So if you prefer the choice that computeNormFactors makes, it seems easy enough to do?

ADD COMMENT
0
Entering edit mode

Thank you James for your response. Yes, that's true and I read about this option, as well. But that would mean, that I have to extract the counts from the QSEAset, transform it into a DGEList to apply edgeR::calcNormFactors on it, and then add them again as pre-calculated factors to the qsea:addLibraryFactors command, am I right?!

ADD REPLY
0
Entering edit mode

calcNormFactors() runs on any numeric matrix containing counts, so you would do not need to create a DGEList object.

ADD REPLY

Login before adding your answer.

Traffic: 544 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6