Hey,
I hope everything is alright.
I have a question about proc transpose. Is there any way to use my prefix in idlabel?
For example:
I have a variable (which i'm using as idlabel) called "sin_date". This variable is a sequence of YYYYMM (202201, 202202, 202203 ...) and I want use a prefix, like "DT_".
When I transpose my numbers, in this moment, my idlabels are 202201, 202202, 202203... and I want that be DT_202201, DT_202202 ..
How can I do this?
Thanks all!
You cannot do it for LABELS. You will need to modify the data first and use the new variable in the IDLABEL statement.
You could do it for NAMES. But that uses the ID statement not the IDLABEL statement.
Ok! 😞
Thanks, Tom!
A generic comment: what I see seems to imply that you are placing date information into labels and possibly variable names. That sort of wide data set can become quite cumbersome to work with for many tasks as the first step is often something to recover the date information for other uses such as interval calculations.
If this data set is made for only the purpose of printing then perhaps one of Proc Report or Tabulate would be in order instead of creating a data set.
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!
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.