LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (June 2006, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Wed, 14 Jun 2006 18:47:13 -0400
Reply-To:     Venky Chakravarthy <swovcc@HOTMAIL.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Venky Chakravarthy <swovcc@HOTMAIL.COM>
Subject:      Re: Mathematical function for power of??
Comments: To: Sa Polo <solouga5@REDIFFMAIL.COM>

It is worthwhile to have this page bookmarked for future reference:

http://support.sas.com/onlinedoc/913/getDoc/en/lrcon.hlp/a000780367.htm

For your immediate question. The power of x raised to n is represented by:

x**n

So in your case

y = val**po ;

Hope this helps.

Venky Chakravarthy

On Wed, 14 Jun 2006 22:11:49 -0000, sa polo <solouga5@REDIFFMAIL.COM> wrote:

> 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


Back to: Top of message | Previous page | Main SAS-L page