self-organizing map in R

July 19, 2012
By

(This article was first published on One Tip Per Day, and kindly contributed to R-bloggers)

This is my first SOM figure 🙂
Thanks to the som package and example code from Jun Yan. Here is my code for the figure:

require(som)
rpkm <- Tx_rpkm[, -c(1:4)]
rpkm.f <- filtering(rpkm, lt=10, ut=30000, mmr=2, mmd=10)
# rpkm.f=log(rpkm.f+0.1) # this doesn’t really change much of the result
rpkm.f.n <- normalize(rpkm.f)
foo <- som(rpkm.f.n, xdim=5, ydim=5, topol=”rect”, neigh=”bubble”)
png(“../results/clustering.SOM.RNAseq.png”,width=800, height=800)
plot(foo,yadj=0.15, main=”Expression profiles obtained by self-organizing map (SOM) clustering \nof individual mRNA transcript throughout the time-course”, xlab=”Stage: D13 – D14 – D15 – D16 – D17 – D18″)
dev.off()
I am still not very clear how to choose the proper xdim and ydim. Also, what’s the color code for the bar mean?  Hope anyone know SOM could leave comment here. Or, I will read article myself 🙂
Is the normalization necessary?

To leave a comment for the author, please follow the link and comment on their blog: One Tip Per Day.

R-bloggers.com offers daily e-mail updates about R news and tutorials on topics such as: Data science, Big Data, R jobs, visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...



If you got this far, why not subscribe for updates from the site? Choose your flavor: e-mail, twitter, RSS, or facebook...

Comments are closed.

Search R-bloggers


Sponsors

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)