Entering edit mode
ribioinfo
▴
100
@ribioinfo-9434
Last seen 4.4 years ago
Hi, maybe I am doing something wrong but I cannot find a log2FoldChange inside the results of DESeq2:
res = results(dds, contrast=c("cond", test, control)) dRes = as.data.frame(res)
dRes$log2FoldChange[1] [1] 12.62795 dRes[dRes$log2FoldChange == 12.62795,][1] baseMean log2FoldChange lfcSE stat pvalue
[6] padj <0 rows> (or 0-length row.names) dRes[dRes$log2FoldChange >= 12.62795,] baseMean log2FoldChange lfcSE stat pvalue 8602.244 12.62795 0.5325757 23.7111 2.770195e-124 padj 3.928413e-120Same result using directly res without the conversion in data frame.
while:
d = data.frame(a=c(1.2, 1.3), b = c(2.1, 2.2))
d[d$a==1.2,] a b 1 1.2 2.1
Could you please tell if I am filtering the table in the wrong way?
Thank you.
See also R FAQ 7.31 https://cran.r-project.org/doc/FAQ/R-FAQ.html#Why-doesn_0027t-R-think-these-numbers-are-equal_003f
Thank you to all for the information.