pheatmap cell notes
2
1
Entering edit mode
5.9 years ago
shahzad.gcu ▴ 10

Dear All, would you please suggest me any method to integrate cell note function like in heatmap.2 function with pheatmap? I trying to make heatmap with pvalues as cell notes with pheatmap but it does not support cell not function. Is there any way out? Please see below example of heatmap i required. Thanks enter image description here

R • 10k views
ADD COMMENT
0
Entering edit mode
ADD REPLY
0
Entering edit mode

would these numbers be different from the ones in the matrix that is the basis of the actual heatmap? (if you wanted to display the numbers from the underlying matrix, display_numbers = TRUE should do the trick.)

ADD REPLY
0
Entering edit mode

Thanks! Yes that is different information. Display_numbers=TRUE will display only values (regression/correlation) values on which heatmap is based as you said. I have similar matrix with exact dimention but sort of quantitative annotation for each cell.

ADD REPLY
7
Entering edit mode
5.9 years ago

Although it's not well documented, after a hard look at the pheatmap code I realized you could probably just supply a matrix of any values, too. And, indeed, that works:

test_vals <- matrix(rnorm(20), 5, 4)
test_labels <- matrix(1:20, 5, 4) 
pheatmap(test_vals, display_numbers = test_labels)
ADD COMMENT

Login before adding your answer.

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