Color specific genes in cummeRbund scatterplot
1
0
Entering edit mode
@markusnevil-13315
Last seen 5.3 years ago

I have a set of genes from an RNA-seq dataset generated from Wild type and mutant samples. As expected there are a number of genes that significantly differ in gene expression as called by Cufflinks/cuffdiff.

I am trying to create a scatterplot where the genes that significantly change in expression are colored differently than the genes that do not (ex.: Up = red, down = blue, NS = black).

However I can only seem to figure out how to create individual plots in a single color (like only showing the points that are significantly up-regulated in red, but no other points).

I would like to make a single graph with all of the genes plotted, and with the significantly changing genes in specific colors (perhaps even point sizes!). I'm fairly new to using R so any help would really be appreciated.



I have lists of these genes and have generated gene lists using:

>myDOWNGenesIds <- read.table("down>2.txt")

>myDOWNGenes <- getGenes(cuff,myDOWNGenesIds[ ,1])

And I can generate individual scatterplots using:

>s <- csScatter(genes(cuff), "Wild_Type", "Mutant")

>sDown <- csScatter(myDOWNGenes, "Wild_Type", "Mutant")

I can also change aspects of these individual graphs:
>sDown + geom_point(size=3, color="red")

cummerbund • 895 views
ADD COMMENT
0
Entering edit mode
Haiying.Kong ▴ 110
@haiyingkong-9254
Last seen 3.5 years ago
Germany

  I am not familiar with this, but would this be sensible to try?

  First, you need to combine all 3 kinds of gene list files, up, down, and no change. There must be one column that indicates the direction of change, and then you can translate this and get a vector colors. Then, instead of using color="red", you give the color vector to the parameter "color".

ADD COMMENT
0
Entering edit mode

 geom_point(aes(color=color.vector))

ADD REPLY

Login before adding your answer.

Traffic: 239 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