Search
Question: Using non-default thresholds into results call vs subset only (post-results call)
1
gravatar for rodrigoguarischi
2.7 years ago by
rodrigoguarischi10 wrote:

Hi Michael

 

I would like to focus only on genes with fold-change greater than 2 and I also would like to decrease FDR a bit, to 5%. I initially tried: 

> res <- results( dds );
> subset( res , padj <= 0.05 & abs(log2FoldChange) >= 1 );

but than I tried adding alpha and lfcThreshold into to results function:

> res <- results( object = dds, alpha = 0.05, lfcThreshold = 1 );
> subset( res , padj <= 0.05 & abs(log2FoldChange) >= 1 )

I was expecting both to give the same result but I was shocked when I figure out that my gene list decreased from 696 to 153 genes.  Is it because fold-change filter is integrate into p-values calculation? I guess you recommend using the second option once this thresholds will also be incorporated in the independent filtering step, right?

 

Thanks

 

 

 

 

 

ADD COMMENTlink modified 2.7 years ago by Michael Love20k • written 2.7 years ago by rodrigoguarischi10
3
gravatar for Michael Love
2.7 years ago by
Michael Love20k
United States
Michael Love20k wrote:

"Is it because fold-change filter is integrate into p-values calculation?"

Yes. For more details, see ?results, vignette("DESeq2") or the DESeq2 paper.

We recommend using lfcThreshold instead of abs(res$log2FoldChange) > x.

ADD COMMENTlink modified 2.7 years ago • written 2.7 years ago by Michael Love20k

Thank you so much for the response. This was really quick!

ADD REPLYlink written 2.7 years ago by rodrigoguarischi10
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.2.0
Traffic: 122 users visited in the last hour