楼主: lime_kim
1698 2

[问答] 求解一道SAS Base题 [推广有奖]

  • 0关注
  • 0粉丝

本科生

11%

还不是VIP/贵宾

-

威望
0
论坛币
0 个
通用积分
0.0376
学术水平
2 点
热心指数
2 点
信用等级
1 点
经验
634 点
帖子
42
精华
0
在线时间
74 小时
注册时间
2014-8-4
最后登录
2021-12-6

楼主
lime_kim 发表于 2015-2-27 19:09:09 |AI写论文

+2 论坛币
k人 参与回答

经管之家送您一份

应届毕业生专属福利!

求职就业群
赵安豆老师微信:zhaoandou666

经管之家联合CDA

送您一个全额奖学金名额~ !

感谢您参与论坛问题回答

经管之家送您两个论坛币!

+2 论坛币
The contents of the raw data file CALENDAR are listed below:
01012000
The following SAS program is submitted:
data test; infile 'calendar';
    input @1 date mmddyy10.;
    if date='01012000'd then event='January 1st';
run;
Which one of the following is the value of the EVENT variable?
A. 01012000
B. January 1st
C. .(missing numeric value)
D. The value can not be determined as the program fails to execute due to errors.
Answer: D
一直对日期型数据搞得不是很清楚,求问这边出现errors是因为if句应该写成if date='01Jan2000'd么?还是其他的原因?
之前发了一遍没发出去,希望这次可以成功~~~
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

关键词:SAS base Base Determined following determine following contents calendar errors file

沙发
wpfwxn 发表于 2015-2-28 09:03:05
日期只有写成'01Jan2000'd这样才会被sas认为是日期,月份一定是3位

藤椅
lime_kim 发表于 2015-2-28 13:06:51
wpfwxn 发表于 2015-2-28 09:03
日期只有写成'01Jan2000'd这样才会被sas认为是日期,月份一定是3位
好的,谢谢~

您需要登录后才可以回帖 登录 | 我要注册

本版微信群
加好友,备注cda
拉您进交流群
GMT+8, 2025-12-29 18:20