This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Edge R, Error in data.frame(..., check.names = FALSE) : arguments imply differing number of rows: 60649, 0

Hi, I got counting table from HTSeq, now I ran through the pipeline in edgeR. After I got the topTags gene, I created a table to show differential expression and I got an error like this:

Error in data.frame(..., check.names = FALSE) : 
  arguments imply differing number of rows: 60649, 0

This is my script:

genediiffBB$table <- cbind(genediffBB$table, FDR=p.adjust(genediffBB$tablePValue, method='fdr'))

Could you tell what is the problem and solution please? I have attached the row 60649 in the picture, Note. I have already delete the line after 60649 before taking the counting table into edgeR.

Thank you in advance!

enter link description here

edger degs

We can't see the figure but it is likely that FDR=p.adjust(genediffBB$tablePValue, method='fdr')) does not work, please could you tell us the output of str(genediffBB)

Hi this is the output

> str(genediffBB)
Formal class 'DGEExact' [package "edgeR"] with 1 slot
  ..@ .Data:List of 3
  .. ..$ :'data.frame': 60649 obs. of  3 variables:
  .. .. ..$ logFC : num [1:60649] 0 0 0.0352 -0.0755 -0.1706 ...
  .. .. ..$ logCPM: num [1:60649] -3.03 -3.03 5.3 5.34 2.57 ...
  .. .. ..$ PValue: num [1:60649] 1 1 0.907 0.732 0.623 ...
  .. ..$ : chr [1:2] "BB" "others"
  .. ..$ : NULL
  ..$ names: chr [1:3] "table" "comparison" "genes"

You need cbind(genediffBB$table, FDR=p.adjust(genediffBB$table$PValue, method='fdr')), pay attention to the syntax you forgot one $ after genediffBB$table

I have problem in uploading the picture but this is the line 60649 (the last row of my count table)

ENSG00000288725.1   RP11-413H22.3   0   0   0   0   0   0   0   0

It is working. Thank you your much!!

  1. Your image wasn't uploaded properly. Drag-and-drop does not work, use the image control on the toolbar to upload your image.
  2. Please use the formatting bar (especially the code option) to present your post better. You can use backticks for inline code (`text` becomes text), or select a chunk of text and use the highlighted button to format it as a code block. If your code has long lines with a single command, break those lines into multiple lines with proper escape sequences so they're easier to read and still run when copy-pasted. I've done it for you this time.
    code_formatting

I am new to this platform, thank you for your guidance!!

No problem, but you've still not done #1 properly - edit your post and upload your image the right way, please.

1 answer

topTags already adds FDR values automatically, so you should not need to add the FDR column yourself.

Log in to answer this question.