| Date: | Wed, 14 Jun 2006 15:45:55 -0700 |
| Reply-To: | "Terjeson, Mark (IM&R)" <Mterjeson@RUSSELL.COM> |
| Sender: | "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU> |
| From: | "Terjeson, Mark (IM&R)" <Mterjeson@RUSSELL.COM> |
| Subject: | Re: Mathematical function for power of?? |
|
| In-Reply-To: | A<20060614221149.31355.qmail@webmail53.rediffmail.com> |
| Content-Type: | text/plain; charset="iso-8859-1" |
Hi,
data x;
val=24 ;po=4; y=val**po; output;
val=24 ;po=2; y=val**po; output;
val=24 ;po=5; y=val**po; output;
val=24 ;po=1; y=val**po; output;
val=24 ;po=2; y=val**po; output;
run;
Hope this is helpful.
Mark Terjeson
Senior Programmer Analyst, IM&R
Russell Investment Group
Russell
Global Leaders in Multi-Manager Investing
-----Original Message-----
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of sa polo
Sent: Wednesday, June 14, 2006 3:12 PM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Mathematical function for power of??
Hi,
I have a dataset with:
data x;
val=24 ;po=4;
val=24 ;po=2;
val=24 ;po=5;
val=24 ;po=1;
val=24 ;po=2;
run;
I need to calculate the value of a variable y
based on val and po(which is a power of variable).
Is there a mathematical function to
do this
Desired result:
y=24*24*24*24;
y=24*24;
y=24*24*24*24*24;
y=24;
y=24*24
Thanks,
SP
|