Hi all,
i need help with this.
i created a variable Adjgpa with is code
proc means data=merged mean;
var GPA;
run;
data Adjgpa;
set Merged;
adjgpa=(GPA-3.18);
run;
proc print data=Adjgpa (obs=10);
run;
proc contents data=adjgpa;
run;
then i tried to run this code
proc univariate data =merged noprint;
var adjgpa;
histogram ;
run;
and it gives me this error:Variable Adjgpa not found.
what am i doing wrong please
I used this
proc univariate data =adjgpa noprint;
var adjgpa;
histogram ;
run;
and it worked.
Thank you
You seem to point to the wrong table for the proc univariate.
Shouldn't you use Adjgpa?
I used this
proc univariate data =adjgpa noprint;
var adjgpa;
histogram ;
run;
and it worked.
Thank you
Hi @pinkyloop, nicely asked question, showing code and error message (not everyone does), followed by a quick response from @ChrisNZ.
To round it off, it would also be good to mark the response from @ChrisNZ as the solution, which highlights the question as solved for the benefit of others and gives @ChrisNZ further recognition.
Thanks & regards,
Amir.
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
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.