由买买提看人间百态

topics

全部话题 - 话题: nolisting
(共0页)
c*****s
发帖数: 180
1
来自主题: WaterWorld版 - PURE WATER DO NOT NETER PLEASE
Complete the following step to create a new simple index on Sasuser.Revenue
that is based on the key variable Date.
proc datasets library=sasuser nolist;
modify revenue;
index delete flightid;

quit;
c*****s
发帖数: 180
2
来自主题: WaterWorld版 - PURE WATER DO NOT NETER PLEASE
Copying Data Sets
You might want to copy an indexed data set to a new location. You can copy a
data set with the COPY statement in a PROC DATASETS step. When you use the
COPY statement to copy a data set that has an index associated with it, a
new index file is automatically created for the new data file.
General form, PROC DATASETS with the COPY statement:
PROC DATASETS LIBRARY=old-libref ;
COPY OUT=new-libref;
SELECT SAS-data-set-name;
QUIT;
where
* ol
c*****s
发帖数: 180
3
来自主题: WaterWorld版 - PURE WATER DO NOT NETER PLEASE
Renaming Data Sets
Another common task is to rename an indexed data set. To preserve the index,
you can use the CHANGE statement in PROC DATASETS to rename a data set. The
index file will be automatically renamed as well.
General form, PROC DATASETS with the CHANGE statement:
PROC DATASETS LIBRARY=libref ;
CHANGE old-data-set-name = new-data-set-name;
QUIT;
where
* libref names the SAS library where the data set is stored
* old-data-set-name is the current name
c*****s
发帖数: 180
4
来自主题: WaterWorld版 - PURE WATER DO NOT NETER PLEASE
Renaming Data Sets
Another common task is to rename an indexed data set. To preserve the index,
you can use the CHANGE statement in PROC DATASETS to rename a data set. The
index file will be automatically renamed as well.
General form, PROC DATASETS with the CHANGE statement:
PROC DATASETS LIBRARY=libref ;
CHANGE old-data-set-name = new-data-set-name;
QUIT;
where
* libref names the SAS library where the data set is stored
* old-data-set-name is the current name
c*****s
发帖数: 180
5
来自主题: WaterWorld版 - PURE WATER DO NOT NETER PLEASE
Renaming Variables
You have seen how to use PROC DATASETS to rename an indexed data set.
Similarly, you might want to rename one or more variables within an indexed
data set. In order to preserve any indexes that are associated with the data
set, you can use the RENAME statement in the DATASETS procedure to rename
variables.
General form, PROC DATASETS with the RENAME statement:
PROC DATASETS LIBRARY=libref ;
MODIFY SAS-data-set-name;
RENAME old-var-name-1 = new
o****o
发帖数: 8077
6
来自主题: Statistics版 - SAS快捷键问题
1. F8 WITH SELECTED CODE
2. proc datasets library=work nolist;
delete _all_/mtype=data;
quit;
3. what do u mean by remove options? there are always default options (
system, data step...)

right click->submit selection.
in SAS?
explorer->library->work->delete all manually.
l*********s
发帖数: 5409
7
来自主题: Statistics版 - 简历问题请教
nolisting
y********0
发帖数: 638
8
象aloud说的,sashelp.vcolumns里,dictionary.columns都有这些变量信息.
用proc datasets 或者 contents都能输出.
可以把两个文件的名字列表各自输出,然后再merge一下.
这是我能想到的方法,不知道有没有更简单的.
譬如:
proc datasets lib=work nolist;
contents data=one out=vone (keep=name label);
contents data=two out=vtwo (keep=name label);
quit;
data vcombine;
merge vone(in=in_one) vtwo(in=in_two);
by name;
if in_one and in_two then from="AB";
else if in_one and in_two=0 then from="A";
else from="B";
run;

name
件?
y********0
发帖数: 638
9
en.是用个宏把名字串起来就可以了.不知道大家还有没有更简单的.
proc datasets nolist;
contents data=test out=v_list(keep=name);
run;
proc sql noprint;
select name into:v_name separated by '.'
from v_list;
quit;
%let NM=is not missing;
%macro v_func;
data
%do i=1 %to 4;
v_&i(keep=id %scan(&v_name,(&i)+1,.) where=(%scan(&v_name,(&i)+1,.) &NM))
%end;
;
set test;
run;
%mend;
%v_func
data all;
merge v_1-v_4;
by id;
if first.id;
run;
d********i
发帖数: 193
10
proc datasets nolist nodetails;
delete mac:;
run;
quit;
h*********n
发帖数: 278
11
来自主题: Statistics版 - 有人对SAS server熟吗?
谢谢!我现在是在每个program后面都加了一条,proc datasets lib=work nolist
kill;quit;
run;
这是不是算手动清空了?
不好意思, 不知道这个df -a 是在哪里run,怎么run的? 对server的东西实在不太懂。
(共0页)