Kaitlyn’s notebook: Extracting clusters from heatmap (and a Venn diagram)

Extracting Clusters

I’ve been working on extracting the clusters out from my heatmap and finally succeeded with this R script!

Cluster 1 

Cluster 2


29C 23C 29C
Mean Protein Abundance 181.025 168.728 284.94 301.742

Important note:

  • distfun = function(x) as.dist(1 - cor(t(x), use = "pa"))
    • heatmap3 states that distfun=dist is default but that is incorrect and the above is the appropriate default;
    • gplots does have the correct distfun=dist default so you  must change it if heatmap3 gives a better dendrogram as in this case.

Question: Should I get error rates for the mean protein abundance of each cluster and silo?

I’m currently working on doing the same thing with the ASCA temperature influenced proteins (the ASCA table requires some different reformatting).

Venn Diagram

I had a lot of trouble trying to make a venn diagram in R (here is my attempt…). I did use the previous script to sort out a list of the proteins in each temperature, but ultimately I decided to refer back to Emma’s paper (2) and use Venny (2) the same way she did.

(1) Oliveros, J. C. Venny. An interactive tool for comparing lists with Venn’s diagrams.
https://bioinfogp.cnb.csic.es/tools/venny/index.html (accessed February 13, 2019).

(2) Timmins-Schiffman, E. B., Crandall, G. A., Vadopalas, B., Riffle, M. E., Nunn, B. L., Roberts, S. B. (2017). Integrating Discovery-driven Proteomics and Selected Reaction Monitoring To Develop a Noninvasive Assay for Geoduck Reproductive Maturation. Journal of Proteome Research, 16(9), 3298–3309.doi:10.1021/acs.jproteome.7b00288.