由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Statistics版 - sas低手请教一个output问题
相关主题
help: proc logisticSAS question
SAS菜鸟请教如果使SAS的output的结果放到一个文件内?求教一个简单的data step 牛肉包
请教一sas codesas proc means 问题
如何比较两个proc contents的结果?请问SAS如何把put的内容输出到output窗口
SAS DATA 求助SAS format 的问题
问个SAS入门级的问题。。多谢。。could anybody please help check why my codes don't work? Thanks!
[SAS] data set options (obs=) in output tables从大data 产生多个小data 的方法
如何从sas output里读入数据。问个效率问题 SQL vs data step,大数据量
相关话题的讨论汇总
话题: 003话题: 001话题: asd话题: output话题: proc
进入Statistics版参与讨论
1 (共1页)
z**********i
发帖数: 12276
1
有个dataset:
ID var
001 blood
001 asd
001 sdf
002 blood
002 asd
003 asd
003 all
003 afjl
如何把它们按照ID, output到3个单独的page上。
page1:
001 blood
001 asd
001 sdf
page2:
002 blood
002 asd
page3:
003 asd
003 all
003 afjl
多谢!!
y******0
发帖数: 401
2
I am not sure what you meant.
If you want to output to three different datasets, let the dataset called:
page
data page1 page2 page3;
set page;
if id='001' then output page1;
if id='002' then output page2;
if id='003' then output page3;
run;
Then you can get three datasets.
If you want to print out, you can do like:
proc sort data=page;
by ID;
run;
proc report data=page;
by ID;
column ID var;
define ID/display;
define var/display;
run;
g*******y
发帖数: 380
3
如果是指output window里分页的话,在sas tutorial里找找.
我记得我复习考试的时候在里面看到过.
g*******y
发帖数: 380
4
找到了,不知道是不是你所指的意思.
General form, PAGEBY statement:
PAGEBY BY-variable;
where BY-variable identifies a variable that appears in the BY statement in
the PROC PRINT step. PROC PRINT begins printing a new page if the value of
any of the variables in the BY statement changes.
The variable specified in the PAGEBY statement must also be specified in the
BY statement in the PROC PRINT step.
z**********i
发帖数: 12276
5
为啥看到回帖泥?

【在 z**********i 的大作中提到】
: 有个dataset:
: ID var
: 001 blood
: 001 asd
: 001 sdf
: 002 blood
: 002 asd
: 003 asd
: 003 all
: 003 afjl

z**********i
发帖数: 12276
6
多谢!!

【在 y******0 的大作中提到】
: I am not sure what you meant.
: If you want to output to three different datasets, let the dataset called:
: page
: data page1 page2 page3;
: set page;
: if id='001' then output page1;
: if id='002' then output page2;
: if id='003' then output page3;
: run;
: Then you can get three datasets.

z**********i
发帖数: 12276
7
你简直是我的saver.
options nodate;
ods pdf file="D:/dataname.pdf";
*ods pdf StartPage=Never;
Title1 'report';
proc print data=missing;
by id;
pageby id;
run;
ods pdf close;
这样就得到按ID单独分页的pdf文件了。
非常感谢!!

in
the

【在 g*******y 的大作中提到】
: 找到了,不知道是不是你所指的意思.
: General form, PAGEBY statement:
: PAGEBY BY-variable;
: where BY-variable identifies a variable that appears in the BY statement in
: the PROC PRINT step. PROC PRINT begins printing a new page if the value of
: any of the variables in the BY statement changes.
: The variable specified in the PAGEBY statement must also be specified in the
: BY statement in the PROC PRINT step.

1 (共1页)
进入Statistics版参与讨论
相关主题
问个效率问题 SQL vs data step,大数据量SAS DATA 求助
a sas merge question问个SAS入门级的问题。。多谢。。
PROC SQL join data help[SAS] data set options (obs=) in output tables
SAS help : Proc dataset如何从sas output里读入数据。
help: proc logisticSAS question
SAS菜鸟请教如果使SAS的output的结果放到一个文件内?求教一个简单的data step 牛肉包
请教一sas codesas proc means 问题
如何比较两个proc contents的结果?请问SAS如何把put的内容输出到output窗口
相关话题的讨论汇总
话题: 003话题: 001话题: asd话题: output话题: proc