Hi,
I have a dataset that looks something like this
data have;
infile datalines;
input patid $4. therapycode1 $10. visit1 duration_to_next_treatment1
therapycode2 $9. visit2 duration_to_next_treatment2
therapycode3 $9. visit3 duration_to_next_treatment3;
datalines;
A1 FL+MM 1 100 LL+NM 2 70 FL+MM 3 40
A2 LL+MN 1 80 CC+WW 2 20 CC 3 60
A3 ZZ+BB+NN 1 50 ZZ+QQ+NN 2 66
A4 ZW+BR+MM 1 11 BR+HH 2 40 YY 3 44
A5 ZZ+BB+NN 1 0 CC 2 55
A6 ZZ+BK+NN 1 200 ZZ+BK*NN 2 6 ZZ+AA*SS 3 20
A7 QQ+HH 1 30 GG 2 89 3 15
A8 XX+CC 1 15 PP+DD+HH 2 11
A9 HH 1 70 ZZ+UU 2 33 DD+UU 3
A10 LL 1 300 TT+GG+RR 2 20 XX+BB 3 88
. .
. .
. .
. .
. .
A90 1 88
;
run;
The dataset has about 90 patients, the variables goes from about therapycode1, visit1, duration_to_next_treatment1 --therapycode9, visit9, duration_to_next_treatment9
I would like to represent this with a swimmer plot, I really don't know how to go about this, I have been racking my brain all day. Maybe someone can help.
I will really appreciate that
I don't understand this. What do you want to represent exactly?
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!
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.