[R-sig-hpc] papply help
Nathan S. Watson-Haigh
nathan.watson-haigh at csiro.au
Tue May 19 04:17:16 CEST 2009
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I have some code that simply takes a matrix and raises all the values to a given
power:
<code>
m <- matrix(0.8, 10, 10)
beta <- 6
m <- m^beta
</code>
I'd like to parallelise this so that each slave executes the calculation on each
of the rows from the matrix. Would this yield any speedup given than my matrix
could be a 10,000 - 15,000 square?
The papply library/function seems like just the trick, but I can't seem to get
it to work....maybe the docs are confusing me as I'm not sure what the different
arguments are actually doing!
Any pointers welcomed :o)
Nathan
- --
- --------------------------------------------------------
Dr. Nathan S. Watson-Haigh
OCE Post Doctoral Fellow
CSIRO Livestock Industries
Queensland Bioscience Precinct
St Lucia, QLD 4067
Australia
Tel: +61 (0)7 3214 2922
Fax: +61 (0)7 3214 2900
Web: http://www.csiro.au/people/Nathan.Watson-Haigh.html
- --------------------------------------------------------
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iEYEARECAAYFAkoSFqwACgkQ9gTv6QYzVL5icACfdHqTFcNDuJU0s9OoRYxC1EMr
oS4AoMiaYWPnoZpjgui1J4FNEFtEwgFt
=WCEH
-----END PGP SIGNATURE-----
More information about the R-sig-hpc
mailing list