Unconfigured Ad

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • id0
    Senior Member
    • Sep 2012
    • 130

    #1

    DESeq2 multiple levels

    I loaded a set of samples into DESeq2 with one factor that has three levels. There is a single condition I called "Type" with three levels A, B, C.

    This is what I did:
    Code:
    > ddsHTSeq <- DESeqDataSetFromHTSeqCount(sampleTable = sampleTable, directory = directory, design = ~ Type)
    > dds <- DESeq(ddsHTSeq, betaPrior=FALSE)
    > resultsNames(dds)
     [1] "Intercept"             "Type_B_vs_A"    "Type_C_vs_A"
    I can use contrasts to run any of the pairwise comparisons. What if I want to get the differences between all three factors? Is that possible? What is the proper approach for that?
  • Michael Love
    Senior Member
    • Jul 2013
    • 333

    #2
    See the LRT section of the main vignette:

    3.6 Likelihood ratio test

    One reason to use the likelihood ratio test is in order to test the null hypothesis that log2 fold changes for multiple levels of a factor ... are equal to zero.

    Comment

    • id0
      Senior Member
      • Sep 2012
      • 130

      #3
      Thanks for pointing that out. I didn't notice that before.

      The example output is:
      Code:
      ## log2 fold change: condition treated vs untreated
      ## LRT p-value: '~ condition' vs '~ 1'
      ## DataFrame with 2 rows and 6 columns
      ##             baseMean log2FoldChange lfcSE     stat      pvalue    padj
      ##             <numeric><numeric>      <numeric> <numeric> <numeric> <numeric>
      ## FBgn0000003   0.159  15.0447        195.974   0.791     0.374     NA
      ## FBgn0000008   52.226 0.0281         0.298     0.010     0.920     0.971
      It says p-value is "'~ condition' vs '~ 1'", but what exactly does that mean?

      Comment

      • Michael Love
        Senior Member
        • Jul 2013
        • 333

        #4
        The likelihood ratio test is a standard test, I'd recommend consulting a statistics textbook.

        Or you can also start here:



        ~ condition is what we call the "full" model, it is also called the alternative model

        ~ 1 is what we call the "reduced" model, it is also called the null model

        Here we are testing whether the explanatory power (in terms of the likelihood of the observed data) of including the condition information in the model, when compared to the null model (~ 1 means we fit only an intercept term, i.e., all samples belong to the same group), is more than expected by chance alone.

        Comment

        Latest Articles

        Collapse

        • kinpict.com
          Reply to 16S/ITS Profiling vs. Shotgun Metagenomics: What Changes in Your Workflow?
          by kinpict.com
          The part about this topic feels surprisingly grounded, and the details on the page is the bit that made me slow down. I’d keep <a href="https://kinpict.com/">ai family photo generator</a> bookmarked for later.
          Today, 06:37 PM
        • SEQadmin2
          16S/ITS Profiling vs. Shotgun Metagenomics: What Changes in Your Workflow?
          by SEQadmin2





          NGS has revolutionized clinical microbiology by offering new ways to identify and surveil pathogens without prior knowledge of the target. One popular approach is 16S rRNA and ITS amplicon sequencing, which targets specific microbial markers. But studies are increasingly incorporating shotgun metagenomics, a technique that sequences all DNA from a sample without targeting specific microbial markers. This approach allows more detailed taxonomic classification,...
          10-30-2026, 06:46 AM

        ad_right_rmr

        Collapse

        News

        Collapse

        Topics Statistics Last Post
        Started by SEQadmin2, 11-12-2026, 07:59 AM
        0 responses
        27 views
        0 reactions
        Last Post SEQadmin2  
        Started by SEQadmin2, 11-05-2026, 09:25 AM
        0 responses
        35 views
        0 reactions
        Last Post SEQadmin2  
        Started by SEQadmin2, 11-03-2026, 11:54 AM
        2 responses
        56 views
        0 reactions
        Last Post kinpict.com  
        Started by SEQadmin2, 10-28-2026, 09:57 AM
        0 responses
        175 views
        0 reactions
        Last Post SEQadmin2  
        Working...