BookmarkSubscribeRSS Feed
VOSA_Andy
Calcite | Level 5
I'm attempting to recreate a query in DI that I'm currently running in EG.

However I'm hitting a brick wall when I try and transpose my data. Simple in EG, seems impossible in DI.

Its a small table

Staff_Division(Char),Week_Commencing(Char),Ave_Work_Lost(Numeric)

Staff_Division and Week_Commencing, with the values never changing and from EG the output looks as follows.

Staff_Division WC_4 WC_3 WC_2 WC_1
Division1 x x x x
Division2 x x x x
Division3 x x x x
Division4 x x x x

where x donates the value that was stored in Ave_Work_Lost.

In EG ive set Transpose Var: Ave_Work_lost
Copy variables: blank
New Column names: Week_Commencing
Group analysis by: Staff_Division.
New Column labels: blank.

I've found the same options within DI, however even with a few hours trial and error trying various different combinations of the above and a few more reading guides I'm no closer to achiving what I need.
2 REPLIES 2
Patrick
Opal | Level 21
Hi

This might come too late for you but I couldn't resist trying.

It was actually quite a simple task in DIS 4.2


In the Transpose transformation I've done the following:

Transpose Properties/Options/Assign Columns
Var: Ave_Work_Lost
ID : Week_Commencing
By : Staff_Division

Transpose Properties/Options/Other options
Specify PROC TRANSPOSE options: prefix=WC_


HTH
Patrick
deleted_user
Not applicable
Hey Patrick,

What do you do in the Mappings tab?

Many thanks..

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

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.

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
  • 852 views
  • 0 likes
  • 3 in conversation