|
My apologies for the previous bungled attempt. Let me try this again.
I have this problem with a datastep where I am trying to compute
% change of mean and am getting the following output:
Visit
N
Mean
Standard
Deviation
95% CI
of Mean
% Change
of Mean
Minimum
Median
Maximum
Infusion
16
154.69
104.545
[99.0, 210.4]
-23.6
41.0
112.50
363.0
Infusion
16
154.69
115.196
[93.3, 216.1]
-23.6
27.0
121.00
412.0
Post-Infusion 24hrs
16
118.38
80.941
[75.2, 161.5]
-41.5
31.0
88.50
301.0
Infusion
16
156.56
109.185
[98.4, 214.7]
-22.7
41.0
106.00
380.0
Infusion
16
158.38
114.272
[97.5, 219.3]
-21.8
46.0
115.50
405.0
Post-Infusion 48hrs
16
111.81
76.317
[71.1, 152.5]
-44.8
38.0
77.00
267.0
Post-Infusion 72hrs
15
106.33
76.424
[64.0, 148.7]
-47.5
38.0
74.00
260.0
Day 14
13
145.08
90.202
[90.6, 199.6]
-28.4
40.0
106.00
314.0
Day 21
15
129.80
83.752
[83.4, 176.2]
-35.9
27.0
119.00
369.0
Day 28
15
143.20
94.645
[90.8, 195.6]
-29.3
35.0
112.00
315.0
Day 7
15
101.93
68.342
[64.1, 139.8]
-49.6
32.0
77.00
245.0
Infusion
16
146.63
115.713
[85.0, 208.3]
-27.6
37.0
84.50
427.0
Infusion
17
152.76
109.833
[96.3, 209.2]
33.0
98.00
411.0
Screening
16
156.13
104.834
[100.3, 212.0]
2.199
26.0
115.50
425.0
Infusion
16
1010.44
489.024
[749.9, 1271.0]
561
146.0
930.50
2198.0
Infusion
16
1012.19
530.252
[729.6, 1294.7]
562.5
133.0
923.50
2392.0
Infusion
16
1027.31
521.138
[749.6, 1305.0]
572.4
153.0
914.00
2308.0
Infusion
16
1053.06
558.871
[755.3, 1350.9]
589.3
162.0
959.50
2603.0
The data step computing this is:
data ut1;
set ut0;
by labord tsttxt siunit vstnum vtid ;
length txt $50 cvtid $20 cn $2 cmean $10 csd $10 cmin $10 cmed $10
cmax $10 cci $20 cmpct $5;
if index(tsttxt,'%')^=0 or siunit=' ' then txt=tsttxt;
else txt=trim(left(tsttxt))||' ('||trim(left(siunit))||')';
if vtid=3 then cvtid=trim(left(put(vtid,vtid.)));
else if vtid^=3 then cvtid=trim(left(put(vtid,vtid.)));
cn=put(n,2.);
if bsmean ^=. then cmpct=put(100*(mean-bsmean)/bsmean,best.);
if index(tsttxt,'RFI')>0 then do;
cmean=put(mean,7.1);
csd=put(stddev,7.2);
cmin=put(minimum,7.);
cmed=put(median,7.1);
cmax=put(maximum,7.);
cci='['||compress(put(lowerclmean,7.1))||',
'||compress(put(upperclmean,7.1))||']';
end;
else do;
cmean=put(mean,7.2);
csd=put(stddev,7.3);
cmin=put(minimum,7.1);
cmed=put(median,7.2);
cmax=put(maximum,7.1);
cci='['||compress(put(lowerclmean,7.1))||',
'||compress(put(upperclmean,7.1))||']';
end;
run;
The question is whether or not these % changes of means are correct.
Thanks and regards
Kumar
|