Displaying 20 results from an estimated 1000 matches similar to: "reordering materix presentation in heatmap.2 in the 'gplots' library"
2009 Jul 21
1
problem with heatmap.2 in package gplots generating non-finite breaks
I have written a wrapper for heatmap.2 called
heatmap.w.row.and.col.clust which auto-generates breaks using
breaks<-round((c(seq(from=(-20 * stddev), to=(20 * stddev))))/20,
digits = 2) #(stddev in this case = 2.5)
This has always worked well in the past but now I am getting an error
that non-finite breaks are being generated. Drilling down, it seems
that my wrapper is generating finite
2011 Mar 29
0
Fwd: comparing heatmaps
Thanks Tom.
heatmap.2(mat, Rowv=NA, Colv=NA, col=redgreen, breaks=seq(-1,1,by=0.01), symm=TRUE, trace="none", dendrogram="none")
that did the trick :)
Begin forwarded message:
From: "Leja, Thomas"
Date: 29 March 2011 03:47:59 GMT+01:00
To: "Benton, Paul"
Subject: Re: [R] comparing heatmaps
Yep, you have to specify the range for colours.
I usually
2004 Dec 15
1
hclust and heatmap - slightly different dendrograms?
Good afternoon,
I ran heatmap and hclust on the same matrix x (strictly, I ran
heatmap(x), and hclust(dist(t(x))), and realized that the two
dendrograms were slightly different, in that the left-right
arrangement of one pair of subclusters (columns) was reversed in the
two functions (but all individual columns were grouped correctly).
Looking through the code for heatmap as a most definite
2010 Feb 22
1
rownames cannot allocate vector of size
Hi,
On R 2.10.1 for Windows, when I do the following to duplicate the
structure of a large numeric matrix called matrix1:
matrix2 <- matrix(0,nrow=nrow(matrix1),ncol=ncol(matrix1))
and then
rownames(matrix2) <- rownames(matrix1)
I get a "cannot allocate vector of size xxMb" error
but if I instead do:
rnames <- list()
rnames <- rownames(matrix1)
matrix2 <-
2009 Feb 26
0
How do I retrieve column and row names after comparing two matrices?
Hello, I have two matrices as shown below:
Matrix 1
ID AB1 BC1 CD1 ...
name1 1,1 2,1 0,2 ...
name2 2,0 1,2 1,2 ...
name3 0,2 1,1 2,0 ...
name4 2,0 0,2 0,2 ...
Matrix 2
ID AB2 BC2 CD2 ...
name1 1,1
2007 Aug 18
2
Problem with lsa package (data.frame) on Windows XP
Dear R team,
The following piece of code (to use the lsa package) works fine on my
mac os x, but when I run the same code on Windows XP, it doesn't work
any more.
### code:
library("lsa")
matrix1 = textmatrix("C:\\Documents and Settings\\tine stalmans.TINE.
000\\LSA\\cuentos\\", stemming=TRUE, language="spanish",
minWordLength=2, minDocFreq=1,
2012 Sep 04
2
Read data from .csv file as a matrix and compare the different between two matrix
Hi,
I have two table matrix, and I would like to compare the different between
two matrix.
For example:
Matrix 1:
A B C
A 0 1 0
B 0 0 1
C 0 0 0
Matrix 2:
A B C
A 0 1 0
B 0 0 0
C 0 0 0
Each column which have value 1, should also return value 1. As in this
case/example, the result should appear like this (as below). The result of
this differentiation should also be in matrix
2011 Mar 27
3
comparing heatmaps
Dear all,
I've been trying to find how to compare tow different heatmaps but I'm having trouble getting the colors bar to be the same. I'm doing something like the following:
library(gplots)
dat<-cor(matrix(rnorm(100, m=10), nrow=10))
mat<-cor(matrix(rnorm(100), nrow=10))
dev.new()
heatmap.2(mat, Rowv=NA, Colv=NA, col=redgreen(75), symm=TRUE, trace="none",
2012 Aug 02
1
Filter a matrix with a matrix HELP!
Hi,
just during these vacation days, I'm trying to approach with multicore
package
and I have some troubles with foreach.
What I'm trying to do is to extract a data in coordinate (ii,jj) from a
matrix2,
only if the data in the same coordinate in matrix1 is ==1.
Make this with a nested "for" take a lot of time because I have thousand of
values.
ex.
Binary_hex = NULL
2010 Feb 10
2
system.time provides inaccurate sys.child (PR#14210)
Full_Name: Manuel L?pez-Ib??ez
Version: R version 2.6.2 (2008-02-08)
OS: linux-gnu
Submission from: (NULL) (164.15.10.156)
This is only relevant for CPU intensive child processes. Otherwise, the problem
is not obvious.
Therefore, we need a CPU intensive program like this one:
/************************************/
/*** Compile with: gcc -o timer-test -O0 timer-test.c -lm */
#include
2009 Aug 18
2
Embedding lists in matrices and matrices in lists
Hi,
I'm new to programming, new to R and even new to mailing lists so please
be patient with me. I need to manage many matrices generated by an R
program. These matrices have different dimensions and I'd like to group
them somehow. The best way would be to have a big matrix (let's call it
database) where every element database[x,y] consists of a list of
matrices that all have the
2010 Oct 23
1
bind matrices by row
Hi R-users
I have a series of matrices and I would like to bind them together by
column using a loop (i.e. not writing cbind(matrix1,
matrix2,matrix3....)). The reason is because in my real data set I have
a very large number of matrices.
Example:
matrix1 <- matrix (1:12,4,3)
matrix2 <- matrix (13:24,4,3)
matrix3 <- matrix (25:36,4,3)
matrix4 <- matrix (37:48,4,3)
2007 Nov 19
6
Reg : using two different matrix : how to do t.test
I have two matrix with same dimensions. I want to do t.test using each column from 2 different matrix.
Row n Column names in both matrix are same.
e.g.
Matrix1
id VC1 VC2 VC3
R 1 2 3
R1 4 5 6
R3 7 8 9
Matrix2
id VC1 VC2 VC3
R 10 11 12
R1 13 14 15
R3 16 17 18
want to do t.test using each column (with same name ) using Matrix1 and Matrix2
for eg
2012 Sep 19
4
correlating matrices
Hi,
thank you for taking the time and reading my question. My question is
twofold:
1. I have several matrices with variables and one matrix with water levels.
I want to predict the water level with the data in the other matrices.
Basically,
* mod<-lm(matrix1 ~ matrix2+matrix3)*
( What looks like a minus is meant to be the wiggly minus.)
Of course I could dissemble the matrices and paste
2007 May 04
2
Get the difference between two matrices with different length
Hello,
I have got two matrices with different length. The matrices have 3
columuns. The first two are coordinates. The third is a measurement.
Now I want to get a subtraction between every single value of the
third column (between matrix1 and matrix2), but only if the two
first coordinates in matrix1 and matrix2 are the same.
I tried "FUN=?" in aggregate and ave, but I don't know
2007 Nov 19
1
using two different matrix : how to do t.test
I have two matrix with same dimensions. I want to do t.test using each column
from 2 different matrix.
Column names in both matrix are same.
e.g.
Matrix1
id VC1 VC2 VC3
R 1 2 3
R1 4 5 6
R3 7 8 9
Matrix2
id VC1 VC2 VC3
R 10 11 12
R1 13 14 15
R3 16 17 18
want to do t.test
for eg t.test(Matrix1$VC1, Matrix2$VC1)$p.value
What is the best way to do it. I have dataset with
2004 Feb 24
2
matrix() Help
I have a question related to matrix().
The code below randomly generates 3 Poisson numbers into a 3 by 1 matrix:
> matrix1 <- matrix(rpois(3,lambda=2),nrow=3,ncol=1)
And I use list() to see what they are:
[,1]
[1,] 3
[2,] 1
[3,] 4
, which is what I had intended.
I then I want to randomly generate y Normal numbers into a 3 by 8 matrix. y in this case would be 3, 1, and 4; so
2013 Jan 12
3
heatmap.2 problem
Dear List,
I'm trying to generate a simple heatmap that has each row and column
separated by a black line. However, for some reason this only happens
for the first and last color. The middle color in my colorpanel()
command has an addition horizontal and vertical line that I would like
to get rid off. Any suggestions?
#my code below
my.matrix <- cbind(func.1 =
2006 Feb 11
2
heatmap.2 in gplots (PR#8587)
Full_Name: Shane Neph
Version: 2.2.1
OS: mac os x
Submission from: (NULL) (71.113.43.247)
While I found the names of the package authors and maintainer, I was
unsuccessful in finding any contact information.
The preliminary documentation for heatmap.2 is inconsistent in at least a couple
of places when discussing the suppression of one or more dendrograms (and
column/row ordering in general).
2010 Jan 08
2
How to Merge based on Rows
Let's say that I have a bunch of matrices.
They look like this (pardon using fruit for examples, my actual data tables
are far too enormous):
Matrix1
Apples Oranges Pears
A 5 6 7
B 5 3 4
C 8 9 10
D 11 13 14
E 15 3 8
F 1 4 5