如何获得中位数是SAS?
我写了一个剧本,但它没有告诉我中位数
这是我的剧本:
FILENAME book1 URL "http://www.math.tau.ac.il/~liadshek/Books.txt";
DATA book;
INFILE book1 firstobs=2;
INPUT year numberBooks words copies annual author$;
RUN;
PROC MEANS median;
VAR year numberBooks words copies annual;
OUTPUT out = MeanForData;
RUN;
答案 0 :(得分:1)
此代码适用于Base SAS。
您只需打开输出窗口即可查看结果(通过输出传送系统将其发送到那里)。
答案 1 :(得分:1)
MEDIAN需要在输出上。
FILENAME book1 URL "http://www.math.tau.ac.il/~liadshek/Books.txt";
DATA book;
INFILE book1 firstobs=2;
INPUT year numberBooks words copies annual author$;
RUN;
PROC MEANS;
VAR year numberBooks words copies annual;
OUTPUT out = MeanForData median= /autoname;
RUN;