Question: Distance matrix plot issue
0
gravatar for krushnach80
16 months ago by
krushnach80420
krushnach80420 wrote:

This is my code which i m using to create a distance matrix from my expression value

gendat = read.csv('PRIMARY_CELL_UBI (copy).csv',row.names = 1)
gen <- t(gendat)

dd <- as.dist((1 - cor(gen, method='spearman')/2))
View(dd)

I would like to plot something like this since my expression data consist of two condition compared with normal

I would like to plot something like this since my expression data consist of two condition compared with normal Im not sure if i can pass the data and plot is a heatmap or how do i proceed ?

I would like to get the cluster of genes that is formed when i make the distance matrix

Any suggestion or help would be highly appreciated

R • 887 views
ADD COMMENTlink modified 16 months ago by Joseph Hughes2.6k • written 16 months ago by krushnach80420
1

Google for R heatmap.

ADD REPLYlink written 16 months ago by h.mon21k

yes i create heatmap using pheatmap ,gplot etc .But i never did a distance matrix and used that to plot heatmap.But i would be glad if you could suggest me something more to my code....

ADD REPLYlink written 16 months ago by krushnach80420
1
gravatar for Joseph Hughes
16 months ago by
Joseph Hughes2.6k
Scotland, UK
Joseph Hughes2.6k wrote:

Going through the examples for heatmap.2 should enable you to do what you want.

ADD COMMENTlink written 16 months ago by Joseph Hughes2.6k

I solved it thanks for the info

ADD REPLYlink written 16 months ago by krushnach80420

If this answer helped you solve your question then consider "accepting" it (green check mark). That provides closure to this thread.

ADD REPLYlink written 16 months ago by genomax58k

Perhaps you can post your own answer to your question for the next person who has the same issue.

ADD REPLYlink written 16 months ago by Joseph Hughes2.6k
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: 666 users visited in the last hour