Question: Two-dimensional hierarchically clustered heatmap
0
gravatar for adR
11 weeks ago by
adR50
adR50 wrote:

Dear Scientist, I respectfully would like to get your feedback(tutorial) on the following questions. I have gene expression data from the same Biological replicates of two tissues of the brain(cortex and cerebellum) I want to know if Cortex and Cerebellum genes have similarities in their expression/co-expressed/ for the condition I am studying. I did data normalization using DESeq2. Then, I break the data into two(cortex and cerebellum) for correlation analysis. Now, my question is: (1) How could I extract a cluster of correlated genes between the cortex and cerebellum from the two-dimensional hierarchically clustered heatmap for further analysis? (2) How I could assign color bars for the different clusters of genes in the rows and columns-here theoretically asking color assignment for each cluster in the rows and columns as indicated in WGCNA approach.
Here simulated the data as follow.

## Cortex expression profile 
set.seed(123)  
cortex = matrix(rnorm(1000, 2), 100, 10)
rownames(cortex) = paste0("gene_", 1:100)
colnames(cortex) = LETTERS[1:10]

## cerebellum expression profile 
set.seed(177)
cerebellam = matrix(rnorm(1000, 2), 100, 10)
rownames(cerebellam) = paste0("gen_", 1:100)
colnames(cerebellam) = LETTERS[1:10]

## similarity measure 
Tissue_corrlation = cor(t(cortex), t(cerebellam))

##Heatmap
library(ComplexHeatmap)
Heatmap(Tissue_corrlation ,cluster_rows = as.dendrogram(hclust(dist(Tissue_corrlation))), 
cluster_columns = as.dendrogram(hclust(dist(t(Tissue_corrlation )))))

Thank you!

R heatmap corrlation cluster • 148 views
ADD COMMENTlink modified 11 weeks ago by ATpoint46k • written 11 weeks ago by adR50

Extracting genes or regions per cluster has been asked before

Saving individual clusters from heatmaps

and

https://github.com/jokergoo/ComplexHeatmap/issues/136

For question two please read the manual, I guess the Heatmap Decoration section is relevant: https://jokergoo.github.io/ComplexHeatmap-reference/book/heatmap-annotations.html

ADD REPLYlink written 11 weeks ago by ATpoint46k
Please log in to add an answer.

Help
Access

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