homework ae_trt

16 views
Skip to first unread message

Sumitra

unread,
Sep 12, 2014, 12:09:48 PM9/12/14
to anova...@googlegroups.com
Hi vikas,
I followed  same as your steps,but proc transpose getting  39 errors.my code is

data npct (drop=usubjid _Freq_ _Type_);
merge alln denom;
by trt01pn;
npct=strip(put(numer,5.)) || " (" || strip(put(( numer/denom ) *100 ,5.2)) || ")";
run;
proc print data=npct;
run;.
proc sort data=npct;
by trt01pn aebodsys aedecod;
run;
proc transpose data = npct
 out = tnpct prefix = c;
by  aebodsys aedecod;
id trt01pn;
var npct;
run;
ERROR: The ID value "c0" occurs twice in the same BY group.
NOTE: The above message was for the following BY group:
AEBODSYS=Blood and lymphatic system disorders AEDECOD=' '
ERROR: The ID value "c0" occurs twice in the same BY group.
NOTE: The above message was for the following BY group:
AEBODSYS=Cardiac disorders AEDECOD=' '
ERROR: The ID value "c0" occurs twice in the same BY group.
ERROR: The ID value "c0" occurs twice in the same BY group.
ERROR: The ID value "c0" occurs twice in the same BY group.
ERROR: The ID value "c0" occurs twice in the same BY group.
NOTE: The above message was for the following BY group:
AEBODSYS=Gastrointestinal disorders AEDECOD=' '

Jennifer SUN

unread,
Sep 25, 2014, 4:00:50 PM9/25/14
to anova...@googlegroups.com
Hi Sumitra,

proc sort data=npct;
by trt01pn aebodsys aedecod;
run;
proc transpose data = npct
 out = tnpct prefix = c;
by  aebodsys aedecod;

Your error might due to the by (highlight as red) are different. Which means your data does not sorted correctly
Reply all
Reply to author
Forward
0 new messages