Unconfigured Ad

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Biol
    Junior Member
    • Oct 2016
    • 2

    #1

    Help with DESeq2 in a host-vector-pathogen experiment

    Hi everyone.

    I am trying to use DESeq2 to find DEGs in my experiment, but I am confused about the usage of the formulas and I would be grateful if somebody could help me to clarify it.

    My experiment contain 3 "treatments": plants challenged by both insect vector and pathogen (IP, samples S09-S12), plants challenged with only the insect vector (I, samples S05-08) and healthy plants (H, without insects or pathogen, samples S01-04). Each treatment has 4 replicates, totalling 12 samples (S). I want to find differences between all of the groups (H x I, H x IP, I x IP), since I want to see the effect of both insect feeding and pathogen infection on the host transcriptome.
    I created the following design:

    >colData
    Insect Pathogen
    S01 No No
    S02 No No
    S03 No No
    S04 No No
    S05 Yes No
    S06 Yes No
    S07 Yes No
    S08 Yes No
    S09 Yes Yes
    S10 Yes Yes
    S11 Yes Yes
    S12 Yes Yes

    >design=model.matrix(~Vector + Pathogen, colData)
    >design

    (Intercept) VectorYes PathogenYes
    A01 1 0 0
    A02 1 0 0
    A03 1 0 0
    A04 1 0 0
    A05 1 1 0
    A06 1 1 0
    A07 1 1 0
    A08 1 1 0
    A09 1 1 1
    A10 1 1 1
    A11 1 1 1
    A12 1 1 1

    >dds <- DESeqDataSetFromMatrix(countData = countData,
    colData = colData,
    design = ~ Vector + Pathogen)

    Then, I tried to applied DESeq function to further extract differences using contrasts, but I got the following message:

    > dds = DESeq(dds)

    Error in `contrasts<-`(`*tmp*`, value = contr.funs[1 + isOF[nn]]) :
    contrasts can be applied only to factors with 2 or more levels


    What am I doing wrong? Is this the best design for this type of experiment or should I modify it?

    Thanks in advance for any help
  • dpryan
    Devon Ryan
    • Jul 2011
    • 3478

    #2
    Your contrasts will be a bit simpler to setup if you use the following groups:

    Code:
    colData = data.frame(group=c(rep("Control",4), rep("Vector", 4), rep("VectorPathogen", 4)))
    You can then specify a design of "~group" and contrasts like:

    Code:
    res <- results(dds, contrast=c("group", "VectorPathogen", "Vector"))

    Comment

    Latest Articles

    Collapse

    • SEQadmin2
      Multiomic Liquid Biopsy: What DNA/RNA Panels Reveal That DNA Alone Can’t
      by SEQadmin2



      Tumors contain complex mixtures of cell populations that evolve in response to treatment and host-specific factors. Tissue biopsies provide only static snapshots of a tumor’s state. But what if we could follow that evolution over time using a minimally invasive technique?

      Liquid biopsies can detect tumor-derived material circulating in the bloodstream, providing a way to study treatment response, detect emerging resistance, and discover new biomarkers. Circulating
      ...
      10-14-2026, 09:55 AM
    • SEQadmin2
      New Genomics Technologies Take Aim at Long-Standing Limits
      by SEQadmin2


      Researchers using sequencing and genomics tools often have to make trade-offs. They can choose between speed or scale, short reads or long-range information, or targeted panels or a view of the whole transcriptome. New technologies that have been released this year are built to address those tough choices.

      We asked six companies the same four questions to learn about their latest products. The new technologies bring a lot to the table, including rethinking sequencing
      ...
      09-28-2026, 10:25 AM

    ad_right_rmr

    Collapse

    News

    Collapse

    Topics Statistics Last Post
    Started by SEQadmin2, Yesterday, 11:13 AM
    0 responses
    17 views
    0 reactions
    Last Post SEQadmin2  
    Started by SEQadmin2, Yesterday, 10:48 AM
    0 responses
    18 views
    0 reactions
    Last Post SEQadmin2  
    Started by SEQadmin2, 10-15-2026, 10:52 AM
    0 responses
    36 views
    0 reactions
    Last Post SEQadmin2  
    Started by SEQadmin2, 10-14-2026, 05:39 AM
    0 responses
    42 views
    0 reactions
    Last Post SEQadmin2  
    Working...