Your question is a bit cryptic, Rich. Are you trying to rewrite the voomByGroup() function yourself, to incorporate functionality that the original authors didn't include? I think it might be difficult or dangerous to try to incorporate samples weights into the voomByGroup approach.
voomByGroup isn't part of Bioconductor, so questions about it should be send to the voomByGroup issues page.
I haven't brought voomByGroup into limma because it only works correctly for pretty simple design matrices and so, as currently written, it doesn't fully support the limma pipeline context.
I can tell you though that you can't simply replace voom() with voomLmFit() and set sample.weights=TRUE. Incorporating sample weights into the voomByGroup() approach would be somewhat hard.
Hi Gordon Smyth, can I ask a side question here, as it probably does not merit its own post: I see in voomByGroup when applied to pseudobulk scRNA-seq that the BCV is pretty much a linear function of the number of cells used to form the pseudobulk. Would (given that the smallest bulk still has a good number of cells, whatever that might be, maybe 50), it be beneficial to subsample cells before pseudobulking or does voombyGroup fully take care of this? Based on what I understand, it's exactly designed for these group-specific variations, is it?
Not sure what "points" you are referring to, or what you mean by them being "weighted".
Gordon,
I missed this a few days ago. I meant the sample weighting option.
I will ask on the github page.
Best wishes,
Rich
Your question is a bit cryptic, Rich. Are you trying to rewrite the voomByGroup() function yourself, to incorporate functionality that the original authors didn't include? I think it might be difficult or dangerous to try to incorporate samples weights into the voomByGroup approach.