SAS proc ttest 修改 HO
SAS proc ttest modify HO
我有一个 GENDER=(1/0) INCOME SENIORITY=(1/0) 的数据。我需要 运行 对年龄 = 1 的按性别划分的收入进行测试。
据我所知,HO=0 的默认值,这意味着性别之间没有区别,但是我如何定义一个 HO 来检查 mu of female(gender=1) 是否 =higher= than mu of男(性别=0).
这是我的基本代码:
proc ttest data=l;
var INCOME;
class gender;
where SENIORITY=1;
run;
这变成了单侧检验,因此您使用单尾 p 值。请通过 SAS 大学主页查看免费的 SAS 培训课程,其中包含第一门统计课程 https://communities.sas.com/community/sas-analytics-u,请参阅页面左侧的培训小部件。
如果您有 SAS Communities ID 并已登录,link 会直接将您带到该页面。
http://support.sas.com/ecst1
边选项只影响CI,单尾p值是一样的。方向性取决于您如何建立假设。
SIDES=L
specifies lower one-sided tests, in which the alternative hypothesis indicates a mean less than the null value, and lower
one-sided confidence intervals between minus infinity and the upper
confidence limit.
SIDES=U
specifies upper one-sided tests, in which the alternative hypothesis indicates a mean greater than the null value, and upper
one-sided confidence intervals between the lower confidence limit and
infinity.
我有一个 GENDER=(1/0) INCOME SENIORITY=(1/0) 的数据。我需要 运行 对年龄 = 1 的按性别划分的收入进行测试。 据我所知,HO=0 的默认值,这意味着性别之间没有区别,但是我如何定义一个 HO 来检查 mu of female(gender=1) 是否 =higher= than mu of男(性别=0).
这是我的基本代码:
proc ttest data=l;
var INCOME;
class gender;
where SENIORITY=1;
run;
这变成了单侧检验,因此您使用单尾 p 值。请通过 SAS 大学主页查看免费的 SAS 培训课程,其中包含第一门统计课程 https://communities.sas.com/community/sas-analytics-u,请参阅页面左侧的培训小部件。
如果您有 SAS Communities ID 并已登录,link 会直接将您带到该页面。 http://support.sas.com/ecst1
边选项只影响CI,单尾p值是一样的。方向性取决于您如何建立假设。
SIDES=L specifies lower one-sided tests, in which the alternative hypothesis indicates a mean less than the null value, and lower one-sided confidence intervals between minus infinity and the upper confidence limit.
SIDES=U specifies upper one-sided tests, in which the alternative hypothesis indicates a mean greater than the null value, and upper one-sided confidence intervals between the lower confidence limit and infinity.