Generating cluster heat map
4
1
Entering edit mode
7.0 years ago

I wanted to plot cluster dendrogram for 234 selected microRNA in Control and Study group like following figure. http://i.imgur.com/5DJt2wl.png?1

Could anyone provide me the instruction and script in R programs to make the plot?

R • 3.0k views
ADD COMMENT
0
Entering edit mode
7.0 years ago
Hussain Ather ▴ 990

What you've linked looks like it was made with seaborn.clustermap in python, not R. If you are okay with using python to use seaborn instead of R, you could write it was

import seaborn as sns

fig = plt.figure()
clustermap = sns.clustermap(array)
fig.savefig(output)

in which array is a DataFrame of your data and output is the name of your output file. You can use pandas to create a DataFrame through a few different methods.

ADD COMMENT
0
Entering edit mode
7.0 years ago

For heatmaps in R, look here.

ADD COMMENT
0
Entering edit mode
7.0 years ago
EagleEye 7.6k

I would recommend ComplexHeatmap (comes with more functionality). Check my previous post for simple example code.

ADD COMMENT
0
Entering edit mode
ADD COMMENT

Login before adding your answer.

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