楼主: zyq7547182
4634 18

求助!广义相加模型!(简单sas程序 老是报错) [推广有奖]

  • 0关注
  • 1粉丝

博士生

40%

还不是VIP/贵宾

-

威望
0
论坛币
1511 个
通用积分
3.8021
学术水平
0 点
热心指数
0 点
信用等级
0 点
经验
12370 点
帖子
227
精华
0
在线时间
319 小时
注册时间
2012-5-5
最后登录
2023-11-17

相似文件 换一批

+2 论坛币
k人 参与回答

经管之家送您一份

应届毕业生专属福利!

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

经管之家联合CDA

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

感谢您参与论坛问题回答

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

+2 论坛币
data a;
input rain        pressure wind        T Tmax Tmin rh sun  Case ;
cards;
0        1032.4        0.5        -1.5        3.4        -4.9        56        7.5        8
0        1021.6        1.1        1.8        7.8        -2.7        59        7.8        17
0        1019.6        1.4        4.3        11.4        -0.5        64        7.7        7
0        1025.9        1.3        4.3        9.1        0.6        67        6.6        12
0        1024.7        0.7        2.9        5.9        2.1        63        1.8        10
0        1023        0.6        4        10.4        0        76        7.2        17
......

proc gam;model case=spline(rain)spline(pressure)spline(wind)spline(sun)/dist=poisson  link=log ;score data=a out=b;proc print data= b;run;
SAS输出结果:ERROR: Value of DIST= opt is unrecognized. Only GAUSSIAN, POISSON, BINOMIAL, BINARY, LOGIT, INVGAUSSIAN, and GAMMA are allowed.NOTE: The data set WORK.B has 0 observations and 0 variables.WARNING: Data set WORK.B was not replaced because new file is incomplete.NOTE: PROCEDURE GAM used (Total process time):      real time           0.00 seconds      cpu time            0.00 seconds
15393  proc print data= b;15394  run;NOTE: No variables in data set WORK.B.

请朋友们帮忙啊!(本人初学)


二维码

扫码加我 拉你入群

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

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

关键词:sas程序 unrecognized observations observation recognized 程序 模型

回帖推荐

jingju11 发表于12楼  查看完整内容

Not sure exactly what you need. But P_** is predicted ...; ods output ParameterEstimates = XXX gives a table 'XXX' containing parameters estimates. By the way, that should be almost globally working on all procedures about regression models in SAS. Jingju
书山有路勤为径,学海无涯苦作舟!
沙发
zyq7547182 学生认证  发表于 2013-5-26 08:43:51 |只看作者 |坛友微信交流群
有人帮忙吗?
书山有路勤为径,学海无涯苦作舟!

使用道具

藤椅
oliyiyi 发表于 2013-5-26 08:45:17 |只看作者 |坛友微信交流群
error说的很清楚啦
缺少币币的网友请访问有奖回帖集合
https://bbs.pinggu.org/thread-3990750-1-1.html

使用道具

板凳
zyq7547182 学生认证  发表于 2013-5-26 08:46:15 |只看作者 |坛友微信交流群
oliyiyi 发表于 2013-5-26 08:45
error说的很清楚啦
那老师你给一个对的出来撒???
书山有路勤为径,学海无涯苦作舟!

使用道具

报纸
oliyiyi 发表于 2013-5-26 08:46:21 |只看作者 |坛友微信交流群
DIST= opt is unrecognized
缺少币币的网友请访问有奖回帖集合
https://bbs.pinggu.org/thread-3990750-1-1.html

使用道具

地板
zyq7547182 学生认证  发表于 2013-5-26 08:48:20 |只看作者 |坛友微信交流群
oliyiyi 发表于 2013-5-26 08:46
DIST= opt is unrecognized
Only GAUSSIAN, POISSON,...

我的就是poisson啊
书山有路勤为径,学海无涯苦作舟!

使用道具

7
jingju11 发表于 2013-5-26 09:57:18 |只看作者 |坛友微信交流群
I guess in GAM procedure, because DIST= is same as LINK=, so SAS regards LINK=log as DIST=log, which is unrecognized to SAS. Almost as a rule, the first statement is oftentimes overwritten by the latter one.
Simply speaking, keeping either DIST=poisson or link=poisson, but not necessary both, will work.
Jingju

使用道具

8
zyq7547182 学生认证  发表于 2013-5-26 10:29:26 |只看作者 |坛友微信交流群
jingju11 发表于 2013-5-26 09:57
I guess in GAM procedure, because DIST= is same as LINK=, so SAS regards LINK=log as DIST=log, which ...
谢谢你的热心帮忙,但不是你说的那个问题,我试过了
书山有路勤为径,学海无涯苦作舟!

使用道具

9
jingju11 发表于 2013-5-26 10:48:44 |只看作者 |坛友微信交流群
? strange. are you sure? what is your error then?
Jingju

if sas 9.1.3
model ..=../dist =poisson;
if sas 9.2 or 9.3
model .../dist =poisson
or
model ../link =poisson

使用道具

10
zyq7547182 学生认证  发表于 2013-5-26 11:33:05 |只看作者 |坛友微信交流群
jingju11 发表于 2013-5-26 10:48
? strange. are you sure? what is your error then?
Jingju
不好意思,是这样的。按你说的做,可以运行,之前可能我看错了。但是结果出来的不是想要的对模型的参数估计......只是在每个观测多加了变量 P_....如下所示:
书山有路勤为径,学海无涯苦作舟!

使用道具

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

本版微信群
加好友,备注cda
拉您进交流群

京ICP备16021002-2号 京B2-20170662号 京公网安备 11010802022788号 论坛法律顾问:王进律师 知识产权保护声明   免责及隐私声明

GMT+8, 2024-4-28 19:44