全部版块 我的主页
论坛 数据科学与人工智能 数据分析与数据科学 SAS专版
1772 1
2010-10-06
悬赏 20 个论坛币 已解决
一道SAS基础题重金悬赏,求程序. (题中的参考帮助来自 SAS Certification Prep Guide Base Programming for SAS 9的第14章)

Assignment:


Create a data set with the following attributes. Arrays and material from chapter 14 should help.

Use a do loop to create a variable i that goes from 0 to 9.
 Use a do loop to create a variable j that goes from 0 to 9 for each value of i.
 Create a variable k that is the sum of i times 10 plus j. (k will count from 0 to 99).
 Create an array x of 10 variables named x1 through x10. For each observation, the value of x1 is 1 divided by the current value of k, x2 is 2 over k, x3 is 3 over k, and so on.
Create a variable m that takes the value of `ODD' for odd value of k and `EVEN' for even values of k.
 Create a variable n that takes the value of i written out (i.e. n = `Zero' for i = 0).
 Create a variable o that takes the value of j written out (i.e. o = `Zero' for j = 0).
 Create a variable p that concatenates n and o (no spaces) and converts it to all uppercase.
 Create a variable q that removes all instances of the substring `ON' from p and replaces them with `NO'.
Create a variable r that takes only the rst two characters of q
 Output to the data set for every value of k.


As a hint, the data set should have 100 observations and 19 variables.

HW5.pdf

大小:57.72 KB

 马上下载

题目原本

二维码

扫码加我 拉你入群

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

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

全部回复
2010-10-6 16:33:12
复制代码
二维码

扫码加我 拉你入群

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

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

相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群