ansari.test(stats)
ansari.test()所属R语言包:stats
Ansari-Bradley Test
安萨里-布拉德利测试
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Performs the Ansari-Bradley two-sample test for a difference in scale parameters.
执行安萨里在尺度参数的差异 - 布拉德利两样本测试。
用法----------Usage----------
ansari.test(x, ...)
## Default S3 method:[默认方法]
ansari.test(x, y,
alternative = c("two.sided", "less", "greater"),
exact = NULL, conf.int = FALSE, conf.level = 0.95,
...)
## S3 method for class 'formula'[类formula的方法]
ansari.test(formula, data, subset, na.action, ...)
参数----------Arguments----------
参数:x
numeric vector of data values.
数字矢量数据值。
参数:y
numeric vector of data values.
数字矢量数据值。
参数:alternative
indicates the alternative hypothesis and must be one of "two.sided", "greater" or "less". You can specify just the initial letter.
表示替代假说,必须是一个"two.sided","greater"或"less"。您可以指定只的首字母。
参数:exact
a logical indicating whether an exact p-value should be computed.
逻辑是否应计算一个确切的p值。
参数:conf.int
a logical,indicating whether a confidence interval should be computed.
一个合乎逻辑,是否应计算置信区间。
参数:conf.level
confidence level of the interval.
区间的置信水平。
参数:formula
a formula of the form lhs ~ rhs where lhs is a numeric variable giving the data values and rhs a factor with two levels giving the corresponding groups.
一个公式的形式lhs ~ rhs其中lhs是一个数值变量提供的数据值和rhs的因素有两个级别给予相应的组。
参数:data
an optional matrix or data frame (or similar: see model.frame) containing the variables in the formula formula. By default the variables are taken from environment(formula).
一个可选的矩阵或数据框(或类似:看到model.frame)包含公式formula的变量。默认情况下采取的变量从environment(formula)。
参数:subset
an optional vector specifying a subset of observations to be used.
一个可选的向量,指定要使用的意见的一个子集。
参数:na.action
a function which indicates what should happen when the data contain NAs. Defaults to getOption("na.action").
一个函数,它表示数据时,包含NA的,应该发生什么。 getOption("na.action")默认。
参数:...
further arguments to be passed to or from methods.
进一步的参数被传递到或从方法。
Details
详情----------Details----------
Suppose that x and y are independent samples from distributions with densities f((t-m)/s)/s and f(t-m), respectively, where m is an unknown nuisance parameter and s, the ratio of scales, is the parameter of interest. The Ansari-Bradley test is used for testing the null that s equals 1, the two-sided alternative being that s != 1 (the distributions differ only in variance), and the one-sided alternatives being s > 1 (the distribution underlying x has a larger variance, "greater") or s < 1 ("less").
假设x和y密度分布的独立样本f((t-m)/s)/s和f(t-m),其中m是一个未知的滋扰参数和s ,鳞比,感兴趣的参数。安萨里布拉德利测试用于测试空s等于1,双面替代s != 1(只有在变异的分布有所不同),和片面的替代品是s > 1(分布基本x有一个较大的差异,"greater")s < 1("less")。
By default (if exact is not specified), an exact p-value is computed if both samples contain less than 50 finite values and there are no ties. Otherwise, a normal approximation is used.
(exact如果未指定),默认情况下,一个确切的p值计算,如果这两个样品中含有有限值小于50,有没有关系。否则,一个正常的近似。
Optionally, a nonparametric confidence interval and an estimator for s are computed. If exact p-values are available, an exact confidence interval is obtained by the algorithm described in Bauer (1972), and the Hodges-Lehmann estimator is employed. Otherwise, the returned confidence interval and point estimate are based on normal approximations.
可选,非参数的置信区间和s估计,计算。如果确切的p值,得到一个确切的置信区间鲍尔(1972年)中描述的算法,并采用霍奇斯莱曼估计。否则,返回的置信区间和点估计的基础上正常的近似。
Note that mid-ranks are used in the case of ties rather than average scores as employed in Hollander & Wolfe (1973). See, e.g., Hajek, Sidak and Sen (1999), pages 131ff, for more information.
注意中旬队伍中的关系,而不是作为受聘在霍兰德和沃尔夫(1973)的平均分数的情况下使用。见,例如,哈耶克,Sidak和森(1999),页131ff更多信息,。
值----------Value----------
A list with class "htest" containing the following components:
一类"htest"包含以下组件的列表:
参数:statistic
the value of the Ansari-Bradley test statistic.
安萨里布拉德利测试统计值。
参数:p.value
the p-value of the test.
p值的测试。
参数:null.value
the ratio of scales s under the null, 1.
尺度比s空下,1。
参数:alternative
a character string describing the alternative hypothesis.
字符串描述替代假说。
参数:method
the string "Ansari-Bradley test".
字符串"Ansari-Bradley test"。
参数:data.name
a character string giving the names of the data.
字符串提供的数据的名称。
参数:conf.int
a confidence interval for the scale parameter. (Only present if argument conf.int = TRUE.)
为尺度参数的置信区间。 (目前唯一的参数conf.int = TRUE。)
参数:estimate
an estimate of the ratio of scales. (Only present if argument conf.int = TRUE.)
鳞比的估计。 (目前唯一的参数conf.int = TRUE。)
注意----------Note----------
To compare results of the Ansari-Bradley test to those of the F test to compare two variances (under the assumption of normality), observe that s is the ratio of scales and hence s^2 is the ratio of variances (provided they exist), whereas for the F test the ratio of variances itself is the parameter of interest. In particular, confidence intervals are for s in the Ansari-Bradley test but for s^2 in the F test.
F检验来比较安萨里布拉德利测试结果比较两个差异(常态假设下),观察s尺度的比例,因此,s^2是比(只要它们存在差异),而F检验差异本身的比例是感兴趣的参数。尤其是置信区间为s在安萨里-Bradley的测试,但s^2F检验。
参考文献----------References----------
Constructing confidence sets using rank statistics. Journal of the American Statistical Association 67, 687–690.
Theory of Rank Tests. San Diego, London: Academic Press.
Nonparametric Statistical Methods. New York: John Wiley & Sons. Pages 83–92.
参见----------See Also----------
fligner.test for a rank-based (nonparametric) k-sample test for homogeneity of variances; mood.test for another rank-based two-sample test for a difference in scale parameters; var.test and bartlett.test for parametric tests for the homogeneity in variance.
fligner.test基于秩(非参数)k样本方差同质性试验; mood.test另一个排名基于两个样本测试,在尺度参数的差异;<X >和var.test在方差齐性的参数测试。
ansari_test in package coin for exact and approximate conditional p-values for the Ansari-Bradley test, as well as different methods for handling ties.
ansari_test包coin精确和近似条件的安萨里-Bradley的测试,以及不同的方法处理关系的p值。
举例----------Examples----------
## Hollander & Wolfe (1973, p. 86f):[#霍兰德和沃尔夫(1973,P 86F)。]
## Serum iron determination using Hyland control sera[#血清铁测定海兰对照血清]
ramsay <- c(111, 107, 100, 99, 102, 106, 109, 108, 104, 99,
101, 96, 97, 102, 107, 113, 116, 113, 110, 98)
jung.parekh <- c(107, 108, 106, 98, 105, 103, 110, 105, 104,
100, 96, 108, 103, 104, 114, 114, 113, 108, 106, 99)
ansari.test(ramsay, jung.parekh)
ansari.test(rnorm(10), rnorm(10, 0, 2), conf.int = TRUE)
## try more points - failed in 2.4.1[#尝试多点 - 2.4.1失败]
ansari.test(rnorm(100), rnorm(100, 0, 2), conf.int = TRUE)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|