[BioC] question about heatmap.2
Christof Winter
winter at biotec.tu-dresden.de
Mon Mar 16 17:15:53 CET 2009
Wei Xu wrote, On 16.03.2009 16:52:
> Hi, there,
>
> This is a simple question.
>
> I'm trying to read my data from a .csv file and draw a heatmap with
> heatmap.2.
> Here is my code,
>
> data=read.csv("file.csv", header=T)
> x=as.matrix(data[,2:5])
> heatmap.2(x)
>
> The file.csv includes 5 columns and 118 rows. First columns are the labels
> for the each probe.
>
> ID Temperature Agitation Oxygen Adhesion
> BG03_B01 -0.098 0.013 0.007 0.064
> BG04_A09 0.025 0.013 -0.011 -0.054
> BG04_A11 -0.005 0.000 0.018 0.050
>
> When I had my heatmap, the probes were labeled with the number from 1 to 117
> instead of the ID numbers in the file. My question is how can I label each
> probe in the heatmap with their IDs. Thanks.
>
> Wei
>
Try
heatmap.2(x, labRow=x$ID)
Christof
More information about the Bioconductor
mailing list