152
1153 proc sort data=lbc;
1154 by subject foldername lbdtn lbdtc recordid;
1155 run;
NOTE: There were 399 observations read from the data set WORK.LBC.
NOTE: SAS sort was used.
NOTE: The data set WORK.LBC has 399 observations and 83 variables.
NOTE: Compressing data set WORK.LBC decreased size by 86.67 percent.
Compressed is 2 pages; un-compressed would require 15 pages.
NOTE: PROCEDURE SORT used (Total process time):
real time 0.02 seconds
cpu time 0.01 seconds
1156
1157 proc transpose data=lbc out=trlbcraw;
1158 by subject foldername lbdtn lbdtc recordid;
1159 var na_raw k_raw creat_raw cl_raw BICARB_raw gluc_raw bun_raw ca_raw ua_raw phos_raw mg_raw creact_raw ck_raw bnp_raw;
1160 run;
NOTE: There were 399 observations read from the data set WORK.LBC.
NOTE: The data set WORK.TRLBCRAW has 5586 observations and 8 variables.
NOTE: Compressing data set WORK.TRLBCRAW decreased size by 71.43 percent.
Compressed is 10 pages; un-compressed would require 35 pages.
NOTE: PROCEDURE TRANSPOSE used (Total process time):
real time 0.03 seconds
cpu time 0.03 seconds
1161
1162 proc transpose data=lbc out=trlbcun;
1163 by subject foldername lbdtn lbdtc recordid;
1164 var na_un k_un creat_un cl_un BICARB_un gluc_un bun_un ca_un ua_un phos_un mg_un creact_un ck_un bnp_un;
1165 run;
NOTE: There were 399 observations read from the data set WORK.LBC.
NOTE: The data set WORK.TRLBCUN has 5586 observations and 8 variables.
NOTE: Compressing data set WORK.TRLBCUN decreased size by 83.64 percent.
Compressed is 9 pages; un-compressed would require 55 pages.
NOTE: PROCEDURE TRANSPOSE used (Total process time):
real time 0.05 seconds
cpu time 0.06 seconds
1166
1167 data chem;
1168 merge trlbcraw(in=x1 rename=(col1=LBORRES) drop=_name_ _label_) trlbcun(in=x2 rename=(col1=LBORRESU)drop=_name_ _label_);
1169 by subject foldername lbdtn lbdtc recordid;
1170 if x1;
1171 run;
NOTE: MERGE statement has more than one data set with repeats of BY values.
NOTE: There were 5586 observations read from the data set WORK.TRLBCRAW.
NOTE: There were 5586 observations read from the data set WORK.TRLBCUN.
NOTE: The data set WORK.CHEM has 5586 observations and 7 variables.
NOTE: Compressing data set WORK.CHEM decreased size by 86.54 percent.
Compressed is 7 pages; un-compressed would require 52 pages.
NOTE: DATA statement used (Total process time):
real time 0.05 seconds
cpu time 0.06 seconds
Hi, can somebody help on the merge statement issue. I want the exactly same output but without the Merge statement note. I think Proc Sql can help, but I am not able to figure how to get there. Inputs are appreciated. EDITED: 1:40 PM EST. Thanks Thanks Kurt, wasn't aware about this functionality
... View more