The SAS help community has always been very valuable for a beginner like me. Hoping someone can take the time to please help me again! Here is my code thus far:
filename rawdata '/courses/ddb976e5ba27fe300/NHANES 2013_2014/alcohol.dat';
data Alcohol (keep = SEQN ALQ120Q);
infile rawdata;
run;
proc print data=Alcohol;
run;
***I have no errors, but this warning keeps popping up "The table "WORK.ALCOHOL" cannot be opened because it does not contain any columns."***
Here is my task if more information is needed on what I am trying to do:
The codebook, which shows the variable labels and formats, is available at:
https://wwwn.cdc.gov/Nchs/Nhanes/2013-2014/ALQ_H.htm#SEQN
Import the alcohol.dat data into a temporary SAS data set called Alcohol. The alcohol.dat file is stored in the /courses/ddb976e5ba27fe300/NHANES 2013_2014folder. The data values represent SEQN, ALQ101, ALQ110, ALQ120Q, ALQ120U, ALQ130, ALQ141Q, ALQ141U, ALQ151, and ALQ160, respectively.
The alcohol data set should contain only the following variables:
Sequence Number and Number of Drinks Per Day for the Past 12 Months
The two variables in the Alcohol data set should have permanently assigned variable labels.
You're missing an INPUT statement listing the variables - add that and you should be fine.
You can find the full syntax here -> https://documentation.sas.com/?docsetId=lestmtsref&docsetTarget=n0oaql83drile0n141pdacojq97s.htm&doc...
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.