Displaying 3 results from an estimated 3 matches for "10000x10000".
Did you mean:
10000,10000
2011 Nov 28
2
Principal componet plot from lower triangular matrix file
Hi,
I have a comma separated file with element names in first column like shown
below :
Name_1,0
Name_2,0.8878,0
Name_3,0.6777,0.7643,0
Name_4,0.9844,0.1234,0.1414,0
Original data is a 10000x10000 symmetric matrix (600 MB). To reduce file
size, I have minimized matrix to only lower triangle. Is there a (memory)
efficient way to 1) read file 2) compute first and second principal
components and 3) and plot first vs second PC's ?
In the past, I could do this by :
b <- read.csv("dis...
2007 Apr 23
1
how to convert the lower triangle of a matrix to a symmetricmatrix
Sorry if this answer was already given, or if I miss the point,
but did you have a look to "lowerTriangle" and "upperTriangle" functions
in the "gdata" package ?
# example
# A<-matrix(rnorm(9),3,3)
# B<-B<-matrix(NA,dim(A)[1],dim(A)[2])
# lowerTriangle(B)<-lowerTriangle(A)
# upperTriangle(B)<-lowerTriangle(A)
# diag(B)<-diag(A)
Hope this helps,
2008 Apr 18
0
Fw: efficiently replacing values in a matrix
...ol=10000)
>> system.time(a[1,1] <- 1903908.80385)
> user system elapsed
> 30.840 6.226 41.416
>> is.matrix(a)
> [1] TRUE
>
> Is there a better way to enter values into large matrices? If I have
> to
> spend 41 secs each time I enter into a cell and I have 10000x10000
> cells to
> enter that is impractical!
>
> --Nnamdi
>
> Rolf Turner-3 wrote:
>>
>>
>> On 17/04/2008, at 9:33 AM, Charles C. Berry wrote:
>>
>> <snip>
>>
>>> I'll lay odds that Matthew's 'matrix' is actually...