BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.

DO we have to use NOOBS while using ID? 

1 ACCEPTED SOLUTION

Accepted Solutions
PGStats
Opal | Level 21

I guess you are talking about proc print. I think using a ID statement implies option NOOBS, since the ID variable is supposed to provide observation identification. Compare:

 

proc sort data=sashelp.class out=class; by sex name; run;

proc print data=class; by sex; run;
proc print data=class; by sex; id sex; run;
proc print data=class noobs; by sex; id sex; run;
PG

View solution in original post

3 REPLIES 3
Reeza
Super User

You haven't provided enough info regarding your problem. 

Please explain your question in more detail. 

SamuelRajKandru
Quartz | Level 8
Ummm, I was going through Chapter 4 of the SAS Cert Prep Guide. So inorder to eradicate the OBS column, we use a NOOBS. My question is, do we have to write the NOOBS in the code even when we use an ID statement? Or is it not necessary to mention the NOOBS in the code while using the ID statement?
PGStats
Opal | Level 21

I guess you are talking about proc print. I think using a ID statement implies option NOOBS, since the ID variable is supposed to provide observation identification. Compare:

 

proc sort data=sashelp.class out=class; by sex name; run;

proc print data=class; by sex; run;
proc print data=class; by sex; id sex; run;
proc print data=class noobs; by sex; id sex; run;
PG

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

How to Concatenate Values

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 827 views
  • 0 likes
  • 3 in conversation