Re: [R] speeding up a special product of three arrays

2008-05-09 Thread Vincent Goulet
Le jeu. 8 mai à 17:20, Giuseppe Paleologo a écrit : I am struggling with R code optimization, a recurrent topic on this list. I have three arrays, say A, B and C, all having the same number of columns. I need to compute an array D whose generic element is D[i, j, k] - sum_n A[i, n]*B[j,

Re: [R] speeding up a special product of three arrays

2008-05-09 Thread Dimitris Rizopoulos
/dimitris.htm - Original Message - From: Giuseppe Paleologo [EMAIL PROTECTED] To: r-help@r-project.org Sent: Thursday, May 08, 2008 11:20 PM Subject: [R] speeding up a special product of three arrays I am struggling with R code optimization, a recurrent topic on this list. I have three

Re: [R] speeding up a special product of three arrays

2008-05-09 Thread Vincent Goulet
Subject: [R] speeding up a special product of three arrays I am struggling with R code optimization, a recurrent topic on this list. I have three arrays, say A, B and C, all having the same number of columns. I need to compute an array D whose generic element is D[i, j, k] - sum_n A[i, n]*B[j

[R] speeding up a special product of three arrays

2008-05-08 Thread Giuseppe Paleologo
I am struggling with R code optimization, a recurrent topic on this list. I have three arrays, say A, B and C, all having the same number of columns. I need to compute an array D whose generic element is D[i, j, k] - sum_n A[i, n]*B[j, n]*C[k, n] Cycling over the three indices and subsetting