- data a ;
- input x;
- cards;
- 25
- 23
- 27
- 31
- 32
- 35
- 40
- 38
- 38
- 33
- 27
- 21
- 19
- 24
- 17
- 15
- 14
- 19
- 23
- 22
- ;
- run;
- proc transpose data=a out=a1;
- var x;
- run;
- data b (keep=i j s);
- if _n_=1 then do;
- set a1;
- array p[*] _numeric_;
- end;
- set a ;
- do j= 1 to 17;
- s=0;
- do i = j to j+3;
- s=s+p[i];
- output;
- end;
- end;
- run;
- data c ;
- set b;
- mean=s/4;
- if last.j;
- by j notsorted;
- proc sort nodupkey;by j;
- run;


雷达卡





京公网安备 11010802022788号







