I would like to transpose column sord only. here is the sample data below.
I tried using ID statement. but other columns are also getting transpose.
I cannot imagine what this data set would look like if SORD is split into 2 columns but the other column stay as they are. Please show us.
Also, please take a step back and describe the real problem that this is related to, without reference to SAS or Excel or transforming this data. Most likely, your boss or professor wants you to solve a real problem, they didn't say transform this matrix, they asked you to solve a real problem. What is that real problem?
Also, we prefer data presented as working SAS data step code (examples and instructions). We can't really work with data in screen captures.
Not sure what you mean by transpose.
If you want to make another variable that has the same values as SORD then a simple assignment statement will work.
data want;
set have;
sord2 = sord;
run;
But why?
Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!
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.
Ready to level-up your skills? Choose your own adventure.