How to fix plotMA() error?
1
0
Entering edit mode
2.2 years ago
Chris ▴ 340

Hi all,

I run Step 5.6 in this paper and got:

plotMA(res, ylim=c(−5,5), alpha = 0.01)

Error: unexpected input in "plotMA(res, ylim=c(−"

res <- results(dds, contrast=c(“condition”, “MT”, “WT”))

Would you please tell me how to fix the error below? I almost don't change anything in the paper. I notice that my output is slightly different from the paper such as in Figure 2 a: PC1 85% vs 84%.

Thank you so much!

Deseq2 • 964 views
ADD COMMENT
2
Entering edit mode
2.2 years ago
Dave Carlson ★ 2.0k

My guess is that this just a formatting error with the negative sign introduced by copying from the paper:

plotMA(res, ylim=c(−5,5)...

Change to:

plotMA(res, ylim=c(-5,5)...
ADD COMMENT
1
Entering edit mode

+1

so in other words, remove the - and retype it manually

ADD REPLY
0
Entering edit mode

Thanks Dave Carlson and ATpoint! It is a little tricky to recognize the length of 2 minus symbols is different.

ADD REPLY
0
Entering edit mode

A follow up question is I almost don't change anything, but I got Ensembl gene ID on plots instead of gene symbol in the paper. Would you please tell me why?

ADD REPLY
1
Entering edit mode

I have not read the paper, but the authors may have converted Ensembl IDs to gene symbols without specifically explaining it. There are existing tools/libraries to handle this and many discussion on how to do it for example:

Converting Ensembl gene id to Gene symbol

ADD REPLY

Login before adding your answer.

Traffic: 1898 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6