|
沙发

楼主 |
发表于 2011-2-6 22:29:50
|
只看该作者
Re: TXT文件 导入SAS中,最多可以导入多少个变量,可以允许4000个变量吗?
to happy6886
967 data _null_;
968 file "c:\test.txt";
969 array x{4000};
970 do i=1 to 4000;
971 do j=1 to 4000;
972 x[j]=ranuni(0);
973 end;
974 put x1-x4000;
975 end;
976 run;
NOTE: The file "c:\test.txt" is:
File Name=c:\test.txt,
RECFM=V,LRECL=256
NOTE: 827899 records were written to the file "c:\test.txt".
The minimum record length was 10.
The maximum record length was 256.
NOTE: DATA statement used (Total process time):
real time 15.51 seconds
user cpu time 13.79 seconds
system cpu time 0.85 seconds
Memory 866k
977
978 data matrix;
979 infile "c:\test.txt";
980 input x1-x4000;
981 run;
NOTE: The infile "c:\test.txt" is:
File Name=c:\test.txt,
RECFM=V,LRECL=256
NOTE: 827899 records were read from the infile "c:\test.txt".
The minimum record length was 10.
The maximum record length was 256.
NOTE: SAS went to a new line when INPUT statement reached past the end of a line.
NOTE: The data set WORK.MATRIX has 4000 observations and 4000 variables.
NOTE: DATA statement used (Total process time):
real time 5.51 seconds
user cpu time 4.45 seconds
system cpu time 0.48 seconds
Memory 1237k |
|