Seqanswers Leaderboard Ad

Collapse

Announcement

Collapse
No announcement yet.
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • DESeq Plot Error

    Hi,

    I'm trying to plot the scatterplot of direct vs. moderated log-ratios and I keep getting an error:

    Error in plot.window(...) : need finite 'ylim' values
    In addition: Warning messages:
    1: In min(x) : no non-missing arguments to min; returning Inf
    2: In max(x) : no non-missing arguments to max; returning -Inf

    This is what I have put in:

    > cdsBlind <- estimateDispersions( cds, method="blind" )
    > vsd <- getVarianceStabilizedData( cdsBlind )
    > mod_lfc <- (rowMeans( vsd[, conditions(cds)=="treated", drop=FALSE] ) -
    + rowMeans( vsd[, conditions(cds)=="untreated", drop=FALSE] ))
    > lfc <- res$log2FoldChange
    > finite <- is.finite(lfc)
    > table(as.character(lfc[!finite]), useNA="always")

    -Inf Inf NaN <NA>
    83 212 285 0
    > largeNumber <- 10
    > lfc <- ifelse(finite, lfc, sign(lfc) * largeNumber)
    > plot( lfc, mod_lfc, pch=20, cex=.3,
    + col = ifelse( finite, "#80808040", "red" ) )

    Is it because I am running analysis on samples with no replicates? (I know - not good, but it's all that I have...). Any ideas? Thanks.

  • #2
    Dear Coral Girl

    it looks like your mod_lfc consists of all non-finite values. What are the conditions names in your object cds? Note that in the line

    mod_lfc <- (
    rowMeans( vsd[, conditions(cds)=="treated", drop=FALSE] ) -
    rowMeans( vsd[, conditions(cds)=="untreated", drop=FALSE] ))
    you select columns in the data matrix with the names treated and untreated, and if there are no such columns, rowMeans will return NaN. In this case, you need to modify the above code according to your condition names.

    Hope this helps.
    Wolfgang
    Wolfgang Huber
    EMBL

    Comment


    • #3
      Hi Wolfgang,

      Thank you very much - that was exactly the problem. A rookie mistake on my behalf!

      Comment

      Latest Articles

      Collapse

      • seqadmin
        The Impact of AI in Genomic Medicine
        by seqadmin



        Artificial intelligence (AI) has evolved from a futuristic vision to a mainstream technology, highlighted by the introduction of tools like OpenAI's ChatGPT and Google's Gemini. In recent years, AI has become increasingly integrated into the field of genomics. This integration has enabled new scientific discoveries while simultaneously raising important ethical questions1. Interviews with two researchers at the center of this intersection provide insightful perspectives into...
        02-26-2024, 02:07 PM
      • seqadmin
        Multiomics Techniques Advancing Disease Research
        by seqadmin


        New and advanced multiomics tools and technologies have opened new avenues of research and markedly enhanced various disciplines such as disease research and precision medicine1. The practice of merging diverse data from various ‘omes increasingly provides a more holistic understanding of biological systems. As Maddison Masaeli, Co-Founder and CEO at Deepcell, aptly noted, “You can't explain biology in its complex form with one modality.”

        A major leap in the field has
        ...
        02-08-2024, 06:33 AM

      ad_right_rmr

      Collapse

      News

      Collapse

      Topics Statistics Last Post
      Started by seqadmin, 02-28-2024, 06:12 AM
      0 responses
      21 views
      0 likes
      Last Post seqadmin  
      Started by seqadmin, 02-23-2024, 04:11 PM
      0 responses
      69 views
      0 likes
      Last Post seqadmin  
      Started by seqadmin, 02-21-2024, 08:52 AM
      0 responses
      77 views
      0 likes
      Last Post seqadmin  
      Started by seqadmin, 02-20-2024, 08:57 AM
      0 responses
      67 views
      0 likes
      Last Post seqadmin  
      Working...
      X