Re: [R] exponentiate elements of a whole matrix

2010-10-13 Thread Berwin A Turlach
On Wed, 13 Oct 2010 11:51:39 +0100 "Maas James Dr (MED)" wrote: > I've tried hard to find a way to exponentiate each element of a whole > matrix such that if I start with A > > A = [ 2 3 > 2 4] > > I can get back B > > B = [ 7.38 20.08 > 7.38 54.60] > > I've tried > > B <

Re: [R] exponentiate elements of a whole matrix

2010-10-13 Thread Barry Rowlingson
On Wed, Oct 13, 2010 at 11:51 AM, Maas James Dr (MED) wrote: > I've tried hard to find a way to exponentiate each element of a whole matrix > such that if I start with A > > A = [ 2   3 >      2   4] > > I can get back B > > B = [ 7.38   20.08 >      7.38   54.60] > > I've tried > > B <- exp(A) b

[R] exponentiate elements of a whole matrix

2010-10-13 Thread Maas James Dr (MED)
I've tried hard to find a way to exponentiate each element of a whole matrix such that if I start with A A = [ 2 3 2 4] I can get back B B = [ 7.38 20.08 7.38 54.60] I've tried B <- exp(A) but no luck. Thanks J === Dr. Jim Maas University of