作者AmigoSafin ()
看板Statistics
標題[程式] SAS Base 第116題請益
時間Mon Oct 29 03:31:05 2018
[軟體程式類別]:
SAS
[程式問題]:
資料處理、迴歸、敘述統計、logistic、probit...等
資料處理
[軟體熟悉度]:
新手
[問題敘述]:
想請教大家一下#116
雖然知道答案是syntax error
但網路上對於哪裡不對有不同聲音
想跟大家討論一下
我自己認為是retain 不能用 retain monthsales {12}
[程式範例]:
QUESTION 116
The following SAS program is submitted:
data work.totalsales;
set work.monthlysales(keep=year product sales);
retrain montnsales {12};
array montnsales {12};
doi=1 to 12;
monthsales{i}=sales;
end;
ent+1;
monthsales{ent}=sales;
run;
The data set named WORK.MONTHLYSALES has one observation per month for
each of five years for a total of 60 observations.
Which one of the following is the result of the above program?
A. The program fails execution due to data errors.
B. The program fails execution due to syntax errors.
C. The program runs with warnings and creates the WORK.TOTALSALES data set
with 60 observations.
D. The program runs without errors or warnings and creates the WORK.TOTALSALES
解答為B
謝謝大家~
--
--
※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 129.21.70.23
※ 文章網址: https://webptt.com/m.aspx?n=bbs/Statistics/M.1540755068.A.C15.html