BookmarkSubscribeRSS Feed
Ankur32
Obsidian | Level 7

Hello All'

 

can you please help me to write a macro program in SAS to create the dataset as shown in attached examples.

 

thanks in advance..!!

 

 

2 REPLIES 2
RW9
Diamond | Level 26 RW9
Diamond | Level 26

Read the guidance below the post a question button, and the pop up window (I believe its there now) as to how to post a question to get good answers.  Start by posting test data in the form of a datastep, then show what the output should look like.  Avoid attaching files as these are a security risk and I wouldn't download them.  Clearly show logic between the two.

As I can't see your required output and have no idea on your input dataset I cant say anything other than ask why a macro program is needed?  Write simple Base SAS code first, then if need be macro-tize it, in almost no cases is there a need to use Macro as Base is a fully functional language.

Reeza
Super User

1. This is homework, so at least give it a shot. If you're taking this class I assume you need it at some point so learning it may be worthwhile.

 

2. Post what you've tried and we'll be happy to help you work through it.

 

3. Don't use attachments right now, post it directly into the forum - given the security issues right now, no one should be downloading an xlsx or docx files.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

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
  • 2 replies
  • 417 views
  • 0 likes
  • 3 in conversation