mirror of
https://github.com/andre-wojtowicz/blas-benchmarks
synced 2024-11-22 13:15:28 +01:00
16 lines
174 B
R
16 lines
174 B
R
|
library(rbenchmark)
|
||
|
|
||
|
f = function()
|
||
|
{
|
||
|
set.seed (1)
|
||
|
m <- 1000
|
||
|
n <- 500
|
||
|
A <- matrix (runif (m*n),m,n)
|
||
|
|
||
|
# Matrix multiply
|
||
|
B <- crossprod(A)
|
||
|
}
|
||
|
|
||
|
benchmark(f(), replications=100)
|
||
|
|