Unconfigured Ad

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sindrle
    Senior Member
    • Aug 2013
    • 266

    #1

    edgeR with uneven groups

    Hi!
    I have two groups:

    Healthy=26
    Diabetic=22

    > colnames(design)
    [1] "(Intercept)" "DiseaseDiabetic"
    [3] "DiseaseHealthy:Patients2" "DiseaseDiabetic:Patients2"
    [5] "DiseaseHealthy:Patients3" "DiseaseDiabetic:Patients3"
    [7] "DiseaseHealthy:Patients4" "DiseaseDiabetic:Patients4"
    [9] "DiseaseHealthy:Patients5" "DiseaseDiabetic:Patients5"
    [11] "DiseaseHealthy:Patients6" "DiseaseDiabetic:Patients6"
    [13] "DiseaseHealthy:Patients7" "DiseaseDiabetic:Patients7"
    [15] "DiseaseHealthy:Patients8" "DiseaseDiabetic:Patients8"
    [17] "DiseaseHealthy:Patients9" "DiseaseDiabetic:Patients9"
    [19] "DiseaseHealthy:Patients10" "DiseaseDiabetic:Patients10"
    [21] "DiseaseHealthy:Patients11" "DiseaseDiabetic:Patients11"
    [23] "DiseaseHealthy:Patients12" "DiseaseDiabetic:Patients12"
    [25] "DiseaseHealthy:Patients13" "DiseaseDiabetic:Patients13"
    [27] "DiseaseHealthy:TreatmentAfterTreatment" "DiseaseDiabetic:TreatmentAfterTreatment"

    > fit <- glmFit(d,design)
    Error in glmFit.default(y = y$counts, design = design, dispersion = dispersion, :
    Design matrix not of full rank. The following coefficients not estimable:
    DiseaseDiabetic:Patients12 DiseaseDiabetic:Patients13

    How can I adjust for uneven groups?

    Thanks!
  • dpryan
    Devon Ryan
    • Jul 2011
    • 3478

    #2
    You're trying to test with patients that don't exist (since there are only 11 diabetic patients, you can't look for a DiseaseDiabetic:Patients12 interaction). Presumably you mistyped the design formula (it looks like you used ~Disease:Patients + Disease + Disease:Treatment, which doesn't really make sense given your experiment).

    Comment

    • sindrle
      Senior Member
      • Aug 2013
      • 266

      #3
      Thats exactly what I did, because I dont understand the command...

      design <- model.matrix(~Disease+Disease:Patients+Disease:Treatment)

      I will google some. I dont understand the difference between really basic aspects. i.e. "*" vs "+" vs ":" vs "~".

      I have fiddled around a bit, Ill try some more..


      For future people struggling with the same read this:

      Last edited by sindrle; 10-22-2013, 01:58 PM.

      Comment

      • dpryan
        Devon Ryan
        • Jul 2011
        • 3478

        #4
        Originally posted by sindrle View Post
        I will google some. I dont understand the difference between really basic aspects. i.e. "*" vs "+" vs ":" vs "~".
        Ah, yeah, that'll cause some issues then. Have a look at a few tutorials like this one (or even just the "details" section of "help(lm)" in R) to get a better feel about what these things are actually doing.

        Comment

        • sindrle
          Senior Member
          • Aug 2013
          • 266

          #5
          Thanks!
          I dont even understand why I should read up on linear regression.. Wow, I have alot to learn!

          To sum up the fix for uneven groups:

          Delete alle columns with only zeros i.e.

          design <- design[,-24]

          Comment

          • dpryan
            Devon Ryan
            • Jul 2011
            • 3478

            #6
            FYI, once you've read up on linear models, you'll know why "design <- design[,-c(24,26)]" will fix the error but still not answer the actual biological question you want to ask

            Comment

            • sindrle
              Senior Member
              • Aug 2013
              • 266

              #7
              Oh man, I look forward to that!

              But hold on.. Is this incorrect then?

              fit <- glmFit(d,design)

              #Genes responding to Treatment in healthy patients
              ExHealthy <- glmLRT(fit, coef="DiseaseHealthy:TreatmentTreatment")

              #Genes responding to Treatment in diabetic patients
              ExDiabetics <- glmLRT(fit, coef="DiseaseDiabetic:TreatmentTreatment")

              #Genes responding to Treatment in any group
              ExAny <- glmLRT(fit, coef=25:26)

              #Genes responding differently to Treatment in diabetic vs normals
              ExAny <- glmLRT(fit, contrast=c)

              I dont know what "contrast" does.. Googling that aswell.

              My brain is boiling, must sleep some hours..
              Last edited by sindrle; 10-22-2013, 05:28 PM.

              Comment

              Latest Articles

              Collapse

              • 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
                ...
                Yesterday, 10:25 AM
              • SEQadmin2
                How Immunogenomics Decodes Immunity’s Genetic Blueprint
                by SEQadmin2




                The immune system’s power comes from its genetic diversity, allowing myriad threats to be neutralized through first recognizing foreign antigens. That diversity is also what makes the immune system so difficult to study. Recent advances in sequencing technology and computational biology, however, are giving researchers new tools to understand immune responses and immune-related diseases in greater detail.

                This convergence of genetics, immunology, and computation...
                09-01-2026, 05:41 AM

              ad_right_rmr

              Collapse

              News

              Collapse

              Topics Statistics Last Post
              Started by SEQadmin2, Today, 09:51 AM
              0 responses
              9 views
              0 reactions
              Last Post SEQadmin2  
              Started by SEQadmin2, 09-25-2026, 09:06 AM
              0 responses
              32 views
              0 reactions
              Last Post SEQadmin2  
              Started by SEQadmin2, 09-23-2026, 11:05 AM
              0 responses
              27 views
              0 reactions
              Last Post SEQadmin2  
              Started by SEQadmin2, 09-18-2026, 11:37 AM
              1 response
              47 views
              0 reactions
              Last Post pekgio
              by pekgio
               
              Working...