Question: how to plot heat map
gravatar for raya.girish
24 months ago by
raya.girish20 wrote:

Hello All if my question is very basic please bear with me because heat map i am leaning. I have sample control vs test with 4000 gene . I took the fpkm value of control and test both in excel sheet along with that i also added the gene name in first column. So my first column is gene name 2nd column is fpkm from control 3column is fpkm from test(this file is one which has no significant or FC filter i means it contain all the genes.) i am trying to generate heatmap using R as of now i tried this command:

a <- read.csv("/home/Desktop/heatmap.csv",sep=",",header=true)
b <- as.matrix(a[,2:3]) 
heatmap(b,Rowv=TRUE,col=heat.colors(256),cexCol =1.0,margins=c(10,20),offsetRow =5,scale="row",dendrogram="column")

the above command has generated heatmap but the yaxis that is what i assume are gene name the not visible i means just one dark colour line thats it. how to go about i am not sure please help.

heatmap geneexpression rnaseq • 1.3k views
ADD COMMENTlink modified 9 months ago by Biostar ♦♦ 20 • written 24 months ago by raya.girish20

Can you post the output of head /home/Desktop/heatmap.csv # on command line

or head(a) # in R

ADD REPLYlink modified 24 months ago • written 24 months ago by geek_y8.8k

If you plot 4000 genes you will not be able to read the gene names from the resulting plot labels, the font size will be too small and the labels will overlap, you will only be able to read the names if you plot only the top few genes.

There is another heatmap command in R, heatmap.2 from the gplots package.

ADD REPLYlink modified 24 months ago • written 24 months ago by mastal5112.0k
gravatar for Alex
24 months ago by
Alex20 wrote:

maybe you will like HemI ,it's very convenient

ADD COMMENTlink written 24 months ago by Alex20

What is this Heml? Can you provide the link?

ADD REPLYlink written 24 months ago by venu5.7k

ADD REPLYlink written 23 months ago by Alex20
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 674 users visited in the last hour