楼主: lnlhckao123
1301 5

[问答] 200论坛币请问R*C的参数设置及其意义 [推广有奖]

  • 0关注
  • 3粉丝

副教授

62%

还不是VIP/贵宾

-

威望
0
论坛币
14810 个
通用积分
10.6125
学术水平
7 点
热心指数
4 点
信用等级
4 点
经验
12566 点
帖子
754
精华
0
在线时间
405 小时
注册时间
2010-8-21
最后登录
2025-6-7

楼主
lnlhckao123 发表于 2013-5-19 22:15:07 |AI写论文
200论坛币
请问sas中R*C表检验时有哪些参数(如:1.输出理论值;2.每个R*C检验时除了输出卡方值外,还输出 Fisher 精确检验等等),怎样使用,请给出实例,当然如果一一说出大量参数实在麻烦,就请举出:1.输出理论值;2.每个R*C检验时除了输出卡方值外,还输出 Fisher 精确检验,也可以。请高手指点!谢谢!!

最佳答案

yongyitian 查看完整内容

不是很懂, 看看是不是这些 R*C表检验, 一般使用proc freq 的 table 语句。 如 data class; set sashelp.class; if height le 62 then height_group = 'Hight'; else height_group = 'Low'; run; proc freq data=class; table sex*height_group /chisq expected;/* request statistics and to produce the expected values */ table sex*height_group /relrisk; /* rel ...
关键词:200论坛币 参数设置 0论坛币 论坛币 Fisher
即使在人大经济论坛这个网络世界,我仍以真诚为基础与我的好友进行交往!

沙发
yongyitian 发表于 2013-5-19 22:15:08
不是很懂, 看看是不是这些

R*C表检验, 一般使用proc freq 的 table 语句。 如

data class;
     set sashelp.class;
         if height le 62 then height_group = 'Hight';
         else height_group = 'Low';
run;
  
proc freq data=class;
   table sex*height_group /chisq expected;/* request statistics and to produce the expected values */
   table sex*height_group /relrisk;             /* relative risk measures including the odds ratio  */
                                                            /* and the column 1 and 2 relative risks */  
   table sex*height_group /trend;              /* requests the Cochran-Armitage test for trend */
   table sex*height_group /RELRISK CMH;   /* request the Cochran-Mantel-Hanzel statistics   */
   table sex*height_group /RELRISK CMH;
run;

斜杠/后面的是选项。
没有指定选项时, 只输出 frequency, percent, row percent, column percent and total count.
不想输出的内容可以在选项中指定,比如下面程序不输出 percent, row percent and column percent.

proc freq data=class;
   table sex*height_group / nopercent norow nocol;
run;

具体用那些选项,根据需要做那些统计分析来确定。

sas文件中给出了各种选项和解释。
http://support.sas.com/documenta ... at_freq_sect010.htm

不确定选项时, 可以先用/all; 查看chisq 及 measure 的结果.

Here is an example   of 2x2 contingency table
http://support.sas.com/documenta ... at_freq_sect029.htm
已有 1 人评分学术水平 热心指数 信用等级 收起 理由
lnlhckao123 + 3 + 3 + 3 精彩帖子

总评分: 学术水平 + 3  热心指数 + 3  信用等级 + 3   查看全部评分

藤椅
邓贵大 发表于 2013-5-20 06:57:41
1. The EXPECTED option of TABLES statement displays the expected frequencies to output, while the OUTEXPECT option adds the expected frequencies to the output dataset.
2. The CHISQ option of the TABLES statement requests a chi-square test, while the FISHER option makes the Fisher's exact test available. Alternatively, you may use the EXACT FISHER statement to demand a Fisher's exact test. Actually, Fisher's exact test is an automatic part of the output with the CHISQ option for 2x2 contingency tables.

I don't expect to get your $200 by the way.
已有 1 人评分学术水平 热心指数 信用等级 收起 理由
lnlhckao123 + 1 + 1 + 1 热心帮助其他会员

总评分: 学术水平 + 1  热心指数 + 1  信用等级 + 1   查看全部评分

Be still, my soul: the hour is hastening on
When we shall be forever with the Lord.
When disappointment, grief and fear are gone,
Sorrow forgot, love's purest joys restored.

板凳
lnlhckao123 发表于 2013-5-24 02:17:37
谢谢邓贵大!可否给出实际例子!
即使在人大经济论坛这个网络世界,我仍以真诚为基础与我的好友进行交往!

报纸
lnlhckao123 发表于 2013-5-31 23:16:10
谢谢yongyitian!!
即使在人大经济论坛这个网络世界,我仍以真诚为基础与我的好友进行交往!

地板
lnlhckao123 发表于 2013-5-31 23:36:55
谢谢yongyitian!根据您的链接我找到答案了:
proc freq data=class;
   table sex*height_group / Fisher;
run;
已有 1 人评分学术水平 热心指数 信用等级 收起 理由
yongyitian + 1 + 1 + 1 分析的有道理

总评分: 学术水平 + 1  热心指数 + 1  信用等级 + 1   查看全部评分

即使在人大经济论坛这个网络世界,我仍以真诚为基础与我的好友进行交往!

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

本版微信群
加好友,备注cda
拉您进交流群
GMT+8, 2026-1-1 10:40