Hello Team,
I am deriving one variable with exponential operator and receiving this note.How can we rectify this ?
data lb;
set _lb;
GFR_CKEPI = 101 * min((LBSTRESN/kappa),1)**alpha * max((LBSTRESN/kappa),1)** -1*(3.209) * 0.88**AgeAtLB * SEX_factor2 * RACEO;
run;
Do you maybe have 0**0 or an overflow problem? They would both cause that note.
1 data _null_ ; 2 x=0**0 ; NOTE: Invalid argument(s) to the exponential operator "**". 3 run ; 4 5 data _null_ ; 6 x=2**10000 ; NOTE: Invalid argument(s) to the exponential operator "**". 7 run ;
Do you maybe have 0**0 or an overflow problem? They would both cause that note.
1 data _null_ ; 2 x=0**0 ; NOTE: Invalid argument(s) to the exponential operator "**". 3 run ; 4 5 data _null_ ; 6 x=2**10000 ; NOTE: Invalid argument(s) to the exponential operator "**". 7 run ;
I guess this is due to big constant number.Can we rectify this?
There is a limit on the largest integer, that varies by OS:
13 data _null_ ; 14 x=constant('big') ; 15 put x= ; 16 run ; x=1.797693E308
If your number is bigger that, I think you're out of luck. See e.g.:
https://documentation.sas.com/doc/en/lrcon/9.4/p0ji1unv6thm0dn1gp4t01a1u0g6.htm
@sah_biostat wrote:
I am deriving one variable with exponential operator and receiving this note.How can we rectify this ?
data lb; set _lb; GFR_CKEPI = 101 * min((LBSTRESN/kappa),1)**alpha * max((LBSTRESN/kappa),1)** -1*(3.209) * 0.88**AgeAtLB * SEX_factor2 * RACEO; run;
Please, from now on when you have errors in the log, show us the ENTIRE log for this step (DATA step or PROC).
What do your values of ALPHA look like?
Did you generate this equation with a SAS model procedure? If so, maybe this could be done as scoring data using the information from the model.
You most probably have an overflow error. The actual final value may not overflow, though.
One possibility is to calculate the logarithm of what you want first:
log_GFR_CKEPI = log(101) +log(min((LBSTRESN/kappa),1))*alpha -log(max((LBSTRESN/kappa),1))+log(3.209) +log(0.88)*AgeAtLB +log(SEX_factor2)+ log(RACEO);
GFR_CKEPI=exp(log_GFR_CKEPI);
That way, you can do the calculation, even if there is an overflow along the way - you will then only get an error message from the EXP function if the final value overflows.
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.