dncR / MLSeq-archived

This repository is moved to archive. See "dncR/MLSeq" repository for current changes, issues and bug fixes.
5 stars 1 forks source link

Unnecessary estimateSizeFactors calculation on test data #3

Open hermidalc opened 5 years ago

hermidalc commented 5 years ago

In predict, you estimateSizeFactors on test data then simply replace it with the train size factors: https://github.com/dncR/MLSeq/blob/9f2b484c0399a7d6057be896039ceee97b125535/R/predict.R#L123-L124 No need, if you need the sizeFactors slot for the test object simply:

test.dds <- DESeqDataSetFromMatrix(countData=counts.test, colData=data.frame(row.names=colnames(test.data)), design=~1)
sizeFactors(test.dds) <- sizeF.ts