作者AmigoSafin ()
看板Statistics
标题[程式] 请教SAS资料写入问题
时间Sun Aug 4 11:06:09 2019
[软体程式类别]:
请填入软体程式类别,例如:SAS、SPSS、AMOS、R、STATA、EVIEWS...等
SAS
[程式问题]:
资料处理、回归、叙述统计、logistic、probit...等
资料处理
[软体熟悉度]:
请把以下不需要的部份删除
新手
[问题叙述]:
大家好
不好意思想求救SAS资料写入问题
因为大概半年没碰SAS
纠结了一个小时还是没有办法完整地输入资料
因为输入资料只是做分析的最基本
但没输入资料就没办法继续
想跟大家请益
谢谢!
程式码如下
其实我如果Counts後面不加任何informat
部分的data points in Counts 栏位其实是可以输出的
但就是无法全部 应该是因为value长度的问题
很抱歉小的学艺不精
向各位高手请教 谢谢
[程式范例]:
data activity;
input Age $ Gender $ 8-9 Race $7. Poverty $4. Limitation :$ Counts 4. @@;
cards;
10–14 M whites low Major 5
10–14 M whites med Major 21
10–14 M whites hig Major 21
10–14 M other low Major 53
10–14 M other med Major 102
10–14 M other hig Major 52
10–14 F whites low Major 1
10–14 F whites med Major 11
10–14 F whites hig Major 15
10–14 F other low Major 21
10–14 F other med Major 52
10–14 F other hig Major 28
15–19 M whites low Major 1
15–19 M whites med Major 13
15–19 M whites hig Major 21
15–19 M other low Major 36
15–19 M other med Major 86
15–19 M other hig Major 40
15–19 F whites low Major 6
15–19 F whites med Major 8
15–19 F whites hig Major 17
15–19 F other low Major 42
15–19 F other med Major 73
15–19 F other hig Major 26
10–14 M whites low Other 2
10–14 M whites med Other 14
10–14 M whites hig Other 6
10–14 M other low Other 16
10–14 M other med Other 36
10–14 M other hig Other 21
10–14 F whites low Other 2
10–14 F whites med Other 2
10–14 F whites hig Other 3
10–14 F other low Other 17
10–14 F other med Other 33
10–14 F other hig Other 12
15–19 M whites low Other 2
15–19 M whites med Other 8
15–19 M whites hig Other 7
15–19 M other low Other 28
15–19 M other med Other 42
15–19 M other hig Other 23
15–19 F whites low Other 3
15–19 F whites med Other 7
15–19 F whites hig Other 2
15–19 F other low Other 31
15–19 F other med Other 36
15–19 F other hig Other 29
10–14 M whites low None 102
10–14 M whites med None 336
10–14 M whites hig None 285
10–14 M other low None 827
10–14 M other med None 1518
10–14 M other hig None 667
10–14 F whites low None 87
10–14 F whites med None 304
10–14 F whites hig None 302
10–14 F other low None 846
10–14 F other med None 1452
10–14 F other hig None 687
15–19 M whites low None 91
15–19 M whites med None 326
15–19 M whites hig None 313
15–19 M other low None 888
15–19 M other med None 1509
15–19 M other hig None 725
15–19 F whites low None 115
15–19 F whites med None 344
15–19 F whites hig None 286
15–19 F other low None 817
15–19 F other med None 1500
15–19 F other hig None 716
;
run;
proc print data=activity; run;
--
--
※ 发信站: 批踢踢实业坊(ptt.cc), 来自: 68.180.87.229 (美国)
※ 文章网址: https://webptt.com/cn.aspx?n=bbs/Statistics/M.1564887972.A.21F.html
1F:推 bebe666666: 你加@@就不要限制字元数 还有栏位不要空格 09/16 01:48