[BioC] heatmap for high number of genes
mailinglist.honeypot at gmail.com
Tue Mar 2 23:15:44 CET 2010
On Tue, Mar 2, 2010 at 5:07 PM, avehna <avhena at gmail.com> wrote:
> Hi Steve:
> Thank you so much for your message.
> Yes, I'm using "heatmap.2" to display my genes. Do you know about any
> function in R to rearrange a matrix based on the "high to low"-ordering of
> just one column (treatment)?
You should look at the "order" function.
Type "?order" at the R prompt (w/o the quotes).
If your second column is your treatment column, then something like:
o <- order(X[,2], decreasing=TRUE)
X <- X[o,]
Now the rows of X will be reordered by decreasing order (from column 2).
Graduate Student: Computational Systems Biology
| Memorial Sloan-Kettering Cancer Center
| Weill Medical College of Cornell University
Contact Info: http://cbio.mskcc.org/~lianos/contact
More information about the Bioconductor